MDH 1.78e+3NTRIR3pp 0.0033NADPHQR4 0.00NADH17pp 1.00e+3MALt3pp 0.00D_LACt2pp 1.00e+3G1PPpp -2.00e+3ACONMT 0.00ACALDtex 3.07e+3GLYCTO3 0.00ACONIs 0.00CYTBD2pp 0.000.5PPC 0.360F6Ptex 0.00MALS 0.00HYD3pp 0.0022FBA3 0.00ETOHtrpp 1.00e+3CYTBDpp 0.000.5FUMt2_2pp 0.00GLCP 0.00NO3R2bpp 0.00NADH18pp 1.00e+3DSBAO1 0.00TMAOR2pp 0.00CS 1.32e+3GLGC 0.00GLYCtpp 0.00GLYCTO4 0.00PGI 1.07e+3GLYCtex 1.00e+3QMO3 0.0022GLYOX 0.00PGK -1.00e+3FUMtex 0.00CAT 0.0022ETOHtex 1.00e+3H2tpp -1.00e+3SPODMpp 0.0022G3PD5 0.00PGMT 0.00G6PDH2r -52.5ACS 0.00GLYK 0.00AKGt2rpp 0.00MALt2_2pp 0.00PGL -52.512PPDRtpp 0.00DMSOtpp 0.00ATPS4rpp 1.75e+343NADH16pp 1.00e+3ACKr -1.00e+3GLDBRAN2 0.00RPI 2.05e+3XYLt2pp 0.00G1Ptex -1.00e+3MALtex 0.00CYTBO3_4pp 0.000.5DMSOR1pp 0.00FRUptspp 0.00PPK2r (nd)L_LACD2 0.00PYK 1.88e+3QMO2 0.00L_LACt2rpp 0.00NADH10 0.00GLYCDx 0.00MALt2_3pp 0.00DHAPT 0.00CO2tex -92.6NO3R1bpp 0.00DSBAO2 0.00GLYC3Pabcpp 0.00PPCK 0.00L_LACtex 0.00PDH 1.85ME2 -1.78e+3ACALDtpp 3.07e+3FRUtex 0.00XYLabcpp 0.00FRD3 1.00e+3PPA2 0.00ACt2rpp -2.99e+3HYD2pp 0.0022POX 0.00NADPHQR2 0.00ACONTb 1.32e+3CITtex 0.00RIBabcpp 0.00FUM 1.60EDA 1.00e+3PFL 0.00PPA 0.002NO3R1pp 0.00GLCP2 0.00TMAOR1pp 0.00NADH5 0.00LDH_D 1.00e+3LCARR 0.00PGM -508RPE 1.00e+3FRD2 -0.198NADPHQR3 0.00GLYC3Ptex 0.00PPS 0.00GLBRAN2 0.00G3PD7 0.00GLCptspp 15.0TMAOR2 0.00FDH5pp -0.198SPODM 0.0022SUCCt2_2pp 0.00SUCCt2_3pp 0.00FBP 0.00HYD1pp -1.00e+322TPI -74612PPDRtex 0.00ICL 0.00ICDHyr 1.32e+3D_LACtex 1.00e+3MDH3 0.00FORtex 24.3ENO 508L_LACD3 0.00G3PT 0.00GLCDpp 0.00GLCt2pp 1.00e+3RBK 0.00PTAr 1.00e+3GAPD 1.00e+3CITt3pp 0.00SUCOAS 0.00H2tex -1.00e+3ACONTa 1.32e+3PFK -1.71e+3LALDO2x 0.00ACtex -2.99e+3ATPM 3.15PFK_3 0.00MGSA 0.00NADH9 0.00F6Pt6_2pp 0.00NTRIR2x 0.00CITt7pp 0.00F6PA 1.00e+3MDH2 0.00GLYC3Pt6pp 502PYRt2rpp -3.03e+3GLYCTO2 0.00TKT1 548THD2pp 0.0022SUCCt3pp 0.00PPKr (nd)ALCD2x 1.00e+3SUCCtex -1.00e+3DMSOR2 0.00ALDD2x 0.00G3PD2 959XYLI1 0.00NTRIR4pp 0.0033CITL 0.00FORt2pp 0.00GLCtex_copy1 0.00PYRtex -3.03e+3SUCDi 0.00FORtppi -24.5TALA 548TKT2 452XYLtex 0.00AKGDH 1.00e+3AKGtex 0.00NO3R2pp 0.00LGTHL 0.00ALDD2y 0.00EDD 1.00e+3FRUK 0.00FDH4pp 0.00MOX 0.00CO2tpp -92.8ME1 0.00XYLK 0.00G6Pt6_2pp 0.00NADTRHD 0.00G3PD6 0.00GND -1.05e+3HEX1 0.00DMSOR1 0.00FUMt2_3pp 0.00TMAOR1 0.00FBA -1.71e+3G6PP 0.00RIBtex 0.00FRUpts2pp 0.00ACALD 4.07e+3HCO3E 1.13e+3FHL 0.00GLCS1 0.00G6Ptex 0.00OAADC 0.00DMSOR2pp 0.00LDH_D2 0.00LDH_D2 0.00L_LACD2 0.00GLCptspp 15.0L_LACD3 0.00mal__L_cnad_cnadh_ch_coaa_cq8h2_cno2_ph_ph2o_pq8_cnh4_p2dmmq8_ch_cnadph_c2dmmql8_cnadp_cnadh_ch_cmqn8_cnad_ch_pmql8_ch_ph_cmal__L_plac__D_ph_plac__D_ch_cg1p_ph2o_ppi_pglc__D_pacon_T_camet_cahcys_caconm_cacald_eacald_pglyclt_cglx_cacon_C_ch_co2_ch2o_ch_ppep_ch2o_cco2_ch_cpi_cf6p_ef6p_ph2o_caccoa_cglx_ch_ccoa_ch2_ch_ch_ps17bp_ce4p_cdhap_cetoh_petoh_ch_co2_ch2o_ch_ph_pfum_ph_cfum_cpi_cglycogen_cg1p_cno3_pno2_ph2o_ph_cnadh_ch_pnad_cdsbard_pdsbaox_ptmao_ph_ph2o_ptma_paccoa_ch2o_ccit_ch_ccoa_catp_ch_cppi_cadpglc_cglyc_cglyc_pglyclt_cglx_cg6p_cf6p_cglyc_eo2_ch_co2s_ch2o_clgt__S_ch_cgthrd_catp_c3pg_cadp_c13dpg_cfum_eh2o2_ch2o_co2_cetoh_eh2_ph2_ch_po2s_ph2o2_po2_pglyc3p_cdhap_cnadp_cnadph_c6pgl_ch_cac_catp_ccoa_camp_cppi_catp_ch_cglyc3p_cadp_ch_pakg_ph_cakg_ch_ph_ch2o_c6pgc_ch_c12ppd__R_p12ppd__R_cdmso_pdmso_ch_padp_cpi_ch_catp_ch2o_cnadh_ch_cnad_ch_patp_cadp_cactp_cbglycogen_cr5p_cru5p__D_ch_pxyl__D_pxyl__D_ch_cg1p_emal__L_eo2_ch_ch2o_ch_pdmso_ph2o_pdms_ppep_cfru_pf1p_cpyr_catp_cppi_cpppi_cadp_clac__L_cq8_cq8h2_cadp_ch_catp_co2_co2s_ch_ch_plac__L_ph_cnadh_ch_cnad_cnad_cdha_cnadh_ch_ch_ph_cpep_cpyr_cco2_eco2_pno3_ph2o_pno2_pdsbard_pdsbaox_ph2o_cglyc3p_patp_ch_cpi_cadp_catp_cco2_cadp_clac__L_enad_ccoa_cnadh_cco2_cnadp_cco2_cnadph_cacald_cfru_eh2o_catp_cadp_cpi_ch_c2dmmql8_csucc_c2dmmq8_ch2o_ch_cpi_ch_pac_ph_ch2_ch_ch_ppyr_ch2o_cco2_cac_cnadph_ch_cnadp_ch2o_cicit_ccit_ecit_prib__D_ph2o_catp_cpi_cadp_crib__D_ch_ch2o_c2ddg6p_cg3p_ccoa_cfor_ch2o_ch_cpi_cno3_ch_ch_pno2_ch2o_cpi_ch_ptmao_ptma_ph2o_pnadh_ch_cnad_cnad_ch_cnadh_ch_cnadh_clald__D_cnad_c2pg_cxu5p__D_cmql8_cmqn8_cnadph_ch_cnadp_cglyc3p_eatp_ch2o_camp_cpi_ch_cglyc3p_cdhap_cpep_cpyr_ctmao_ch_ch2o_ctma_cfor_ph_cco2_ph_po2s_ch_ch2o2_co2_csucc_ph_ph_ch_ph_cfdp_ch2o_cpi_ch2_ch_ch_p12ppd__R_enadp_cco2_cnadph_clac__D_emqn8_cmql8_cfor_efor_ph2o_ch2o_cpi_cglc__D_ph2o_ph_pglcn_ph_ph_cglc__D_catp_cadp_ch_cpi_ccoa_cpi_cnad_ch_cnadh_ch_ph_ccoa_catp_cpi_csuccoa_cadp_ch2_eatp_cadp_ch_cnadh_ch_cmthgxl_cnad_cac_eatp_ch2o_cadp_ch_cpi_catp_cs7p_cadp_ch_cpi_cnadh_ch_cnad_cpi_cpi_pnadh_ch_cno2_cnad_cnh4_ch2o_clac__L_cpyr_csucc_csucc_pq8_cq8h2_cpi_cpi_ph_ppyr_ph_cglyclt_cglx_ch_pnadh_cnadp_ch_cnad_cnadph_ch_ph_catp_cadp_cnad_ch_cnadh_csucc_eh2o_cdms_cnad_ch2o_cnadh_ch_cnadp_ch_cnadph_cxylu__D_ch_pno2_pnh4_ph2o_pac_ch_ph_cglc__D_epyr_eq8_cq8h2_cxyl__D_enad_ccoa_cnadh_cco2_cakg_eh_cno3_ch_pno2_ch2o_cnadp_ch2o_cnadph_ch_ch2o_catp_ch_cadp_ch_cfor_pco2_ph_po2_ch2o2_cco2_cnad_cnadh_cco2_catp_ch_cadp_cpi_cg6p_ppi_pglyc3p_cdhap_cnadp_cnadph_cco2_catp_cadp_ch_cdmso_cdms_ch2o_ch_ph_ctmao_ch_ch2o_ctma_ch2o_cpi_crib__D_epep_cpyr_cnad_ccoa_ch_cnadh_cco2_ch2o_ch_chco3_ch_cco2_ch_cadp_cg6p_eh_cco2_ch2o_pdms_ppyr_clac__D_cq8h2_cq8_cpyr_clac__L_cglc__D_pg6p_cmqn8_cpyr_cmql8_cNitrite ReductaseTranshydrogenaseCarbonateMenaquinone Reduction/OxidationATPSynthaseDemethylmenaquinone Reduction/OxidationUbiquinone Reduction/OxidationATP MaintenanceOxidative Stress
  • Map 
    • Save map JSON (Ctrl+S)
    • Clear Background (Ctrl+Shift+I)
    • Export as SVG (Ctrl+Shift+S)
    • Export as PNG (Ctrl+Shift+P)
    • Export as GIF (Ctrl+Shift+G)
    • Clear map
  • Model 
    • Update names and gene reaction rules using model
    • Clear model
  • Data 
    • Clear reaction data
    • Clear gene data
    • Clear metabolite data
  • Edit 
    •  Pan mode (Z)
    • Select mode (V)
    • Add reaction mode (N)
    • Rotate mode (R)
    • Text mode (T)
    • Delete (Del)
    • Undo (Ctrl+Z)
    • Redo (Ctrl+Shift+Z)
    • Align vertical (Alt+L)
    • Align horizontal (Shift+Alt+L)
    • Toggle primary/secondary (P)
    • Rotate reactant locations (C)
    • Select all (Ctrl+A)
    • Select none (Ctrl+Shift+A)
    • Invert selection
  • View 
    • Zoom in (+)
    • Zoom out (-)
    • Zoom to nodes (0)
    • Zoom to canvas (1)
    • Find (F)
    • Show control points (B)
    •  Full screen
    • Settings (,)
  • ?
0.00377.114.1K
Skip to main panel
  • File
  • Edit
  • View
  • Run
  • Kernel
  • Tabs
  • Settings
  • Help
PyPI Manager

Warning

The JupyterLab development team is excited to have a robust third-party extension community. However, we do not review third-party extensions, and some extensions may introduce security risks or contain malicious code that runs on your machine. Moreover in order to work, this panel needs to fetch data from web services. Do you agree to activate this feature?
Please read the privacy policy.

Installed

No entries

Discover

No entries

Open Tabs
Close All

Kernels
Shut Down All

Language servers
Shut Down All

Recently Closed
Forget All

Workspaces
Delete All

default

Terminals
Shut Down All

Escher.ipynb

PIBIC
PDH
PFL
Fluxos melhor caso (PDH e MDH)
Fluxos melhor caso (PDH, MDH e AKGDH)
Exportaçao de malato
//IC After Dan/Escher/
Name
ModifiedLast Modified
  • e_coli_core.jsonlast mo.
  • Escher.ipynb31s ago
  • iJO1366.jsonlast mo.
    [23]:
    import cobra
    from cobra.io import load_json_model
    from cobra.flux_analysis import flux_variability_analysis

    import pandas as pd
    import numpy as np

    from cnapy.core import make_scenario_feasible
    [24]:
    model = load_json_model('EC_iCH360.json')
    [25]:
    model.reactions.get_by_id('EX_o2_e_bw').bounds = (0,0)
    [26]:
    R_imp = ['GLCptspp_fw','PDH_fw','PPC_fw','CS_fw','ACONTa_fw','ACONTa_bw',
    'ACONTb_fw','ACONTb_bw','ICDHyr_fw','ICDHyr_bw','AKGDH_fw','SUCOAS_fw','SUCOAS_bw',
    'FUM_fw','FUM_bw','MDH_fw','MDH_bw']
    [27]:
    def min_value(model,enzyme):
    bound = 0.0
    while True:
    with model:
    model.reactions.get_by_id(enzyme).bounds = (bound,bound)
    solution = model.optimize()

    if solution.objective_value is not None:
    bound -= 0.1

    else:
    return bound

    def max_value(model,enzyme):
    bound = 0.0
    while True:
    with model:
    model.reactions.get_by_id(enzyme).bounds = (bound,bound)
    solution = model.optimize()

    if solution.objective_value is not None:
    bound += 0.1

    else:
    return bound
    [7]:
    print(f'Max flux FUM_bw: {max_value(model,"FUM_bw")}')
    print(f'Min flux FUM_bw: {min_value(model,"FUM_bw")}')
    Max flux FUM_bw: 33.3000000000002
    Min flux FUM_bw: -0.1
    
    /home/cristian/.conda/envs/cnapy-1.2.4/lib/python3.10/site-packages/cobra/util/solver.py:554: UserWarning: Solver status is 'infeasible'.
      warn(f"Solver status is '{status}'.", UserWarning)
    
    Max flux PDH_fw: 11.799999999999974
    Min flux PDH_fw: -19.1
    
    Max flux MDH_fw: 42.00000000000033
    Min flux MDH_fw: -35.10000000000023
    
    Max flux MDH_bw: 42.00000000000033
    Min flux MDH_bw: -2.700000000000001
    
    Max flux PPC_fw: 28.600000000000136
    Min flux PPC_fw: -0.1
    
    Max flux GLCptspp_fw: 0.0
    Min flux GLCptspp_fw: 0.0
    
    FUM_bw flux: 0.0
    PPC_fw flux: 0.41250750342026987
    GLCptspp_fw flux: 9.250127204153337
    PDH_fw flux: 0.0
    MDH_fw flux: 0.0
    MDH_bw flux: 0.0
    
    interactive(children=(FloatSlider(value=0.0, description='fum_bw', max=33.3, step=0.01), FloatSlider(value=0.4…
    [21]:
    Reaction identifierMDH_fw
    NameMalate dehydrogenase
    Memory address 0x7fc7441222c0
    Stoichiometry

    0.00236811413346649 enzyme_pool + mal__L_c + nad_c --> h_c + nadh_c + oaa_c

    0.00236811413346649 enzyme pool pseudometabolite + L-Malate + Nicotinamide adenine dinucleotide --> H+ + Nicotinamide adenine dinucleotide - reduced + Oxaloacetate

    GPRb3236
    Lower bound0.0
    Upper bound1000.0
    [50]:
    Reaction identifierFUM_bw
    NameFumarase
    Memory address 0x7f70707630a0
    Stoichiometry

    0.00694546169257057 enzyme_pool + mal__L_c --> fum_c + h2o_c

    0.00694546169257057 enzyme pool pseudometabolite + L-Malate --> Fumarate + H2O H2O

    GPRb2929 or b1675 or b1612 or b4122 or b1611
    Lower bound0.0
    Upper bound1000.0
    interactive(children=(FloatSlider(value=0.0, description='pdh', max=53.7, step=0.01), FloatSlider(value=0.0, d…
      [1]:
      import pandas as pd
      import matplotlib.pyplot as plt
      import numpy as np

      import cobra
      from cobra.io import load_json_model
      [2]:
      model = load_json_model('iCH360_h2.json')
      Set parameter Username
      Set parameter LicenseID to value 2644080
      Academic license - for non-commercial use only - expires 2026-03-29
      
      [12]:
      resultados = {'NADH':[],'H2':[],'Biomassa':[]}

      for i in np.arange(0.0, 29, 0.1):
      try:
      with model:
      model.reactions.get_by_id('GLCptspp_fw').bounds = (i,i)
      solution = model.optimize()

      if solution.objective_value is not None:
      prod_nadh = sum(model.metabolites.get_by_id('nadh_c').summary(solution).producing_flux['flux'])
      prod_h2 = sum(model.metabolites.get_by_id('h2_c').summary(solution).producing_flux['flux'])
      resultados['NADH'].append(prod_nadh)
      resultados['H2'].append(prod_h2)
      resultados['Biomassa'].append(solution.objective_value)
      except:
      continue
      /home/cristian/.conda/envs/me25/lib/python3.12/site-packages/cobra/util/solver.py:554: UserWarning: Solver status is 'infeasible'.
        warn(f"Solver status is '{status}'.", UserWarning)
      /home/cristian/.conda/envs/me25/lib/python3.12/site-packages/cobra/util/solver.py:554: UserWarning: Solver status is 'infeasible'.
        warn(f"Solver status is '{status}'.", UserWarning)
      
      [13]:
      resultados
      [13]:
      {'NADH': [3.9902612536608015,
        4.224465432530143,
        4.4586696113994835,
        4.6928737902688225,
        4.927077969138161,
        5.161282148007503,
        5.395486326876843,
        5.629690505746185,
        5.863894684615522,
        6.0980988634848625,
        6.332303042354203,
        6.566507221223543,
        6.800711400092883,
        7.034915578962223,
        7.269119757831563,
        7.503323936700905,
        7.737528115570243,
        7.971732294439584,
        8.205936473308924,
        8.440140652178266,
        8.674344831047604,
        8.908549009916943,
        9.142753188786287,
        9.376957367655624,
        9.611161546524967,
        9.845365725394307,
        10.079569904263643,
        10.313774083132984,
        10.547978262002319,
        10.782182440871665,
        11.016386619741004,
        11.250590798610343,
        11.484794977479684,
        11.718999156349028,
        11.703741068810363,
        11.69536044156519,
        11.686979814320017,
        11.678599187074843,
        11.670218559829665,
        11.661837932584493,
        11.653457305339314,
        11.64507667809414,
        11.636696050848963,
        11.628315423603786,
        11.625699755863389,
        11.825894743961936,
        12.026189386036517,
        12.226527882426527,
        12.42686637881657,
        12.627204875206605,
        12.827543371596642,
        13.027881867986682,
        13.22822036437672,
        13.42855886076676,
        13.628897357156797,
        13.829235853546834,
        14.029574349936874,
        14.229912846326911,
        14.430251342716952,
        14.630589839106987,
        14.830928335497024,
        15.031266831887065,
        15.231605328277102,
        15.431943824667144,
        15.632282321057179,
        15.83262081744722,
        16.032959313837253,
        16.233297810227292,
        16.433636306617334,
        16.63397480300737,
        16.834313299397408,
        17.034651795787443,
        17.234990292177486,
        17.435328788567524,
        17.62989305773938,
        17.770778593729432,
        17.971855031122455,
        18.172931468515483,
        18.360577886922282,
        18.415462178558027,
        18.470346470194208,
        18.52523076182999,
        18.580115053465846,
        18.63499934510167,
        18.689883636737488,
        18.744767928373285,
        18.7996522200094,
        18.85453651164517,
        18.909420803280764,
        18.964305094916856,
        19.019189386552696,
        19.074073678188498,
        19.128957969824317,
        19.183842261460445,
        19.238726553096285,
        19.29361084473212,
        19.348495136367905,
        19.40337942800376,
        19.458263719639888,
        19.51314801127564,
        19.56803230291146,
        19.622916594547295,
        19.67780088618342,
        19.73268517781897,
        19.78756946945503,
        19.84245376109063,
        19.897338052726663,
        19.95222234436252,
        20.00710663599867,
        20.061990927634177,
        20.116875219270273,
        20.171759510906075,
        20.226643802541908,
        20.281528094177787,
        20.33641238581384,
        20.39129667744964,
        20.446180969085518,
        20.50106526072132,
        20.55594955235716,
        20.61083384399325,
        20.665718135628794,
        20.72060242726458,
        20.77548671890069,
        20.830371010536815,
        20.885255302172386,
        20.940139593808215,
        20.99502388544397,
        21.049908177080134,
        21.104792468715967,
        21.159676760351758,
        21.214561051987666,
        21.269445343623754,
        21.324329635259524,
        21.379213926895083,
        21.434098218531183,
        21.488982510167002,
        21.543866801802835,
        21.598751093438622,
        21.653635385074786,
        21.708519676710623,
        21.76340396834639,
        21.818288259982168,
        21.873172551618048,
        21.928056843254158,
        21.98294113488994,
        22.0378254265258,
        22.092709718161615,
        22.147594009797402,
        22.20247830143355,
        22.257362593069328,
        22.312246884704933,
        22.367131176341026,
        22.42201546797717,
        22.476899759612717,
        22.531784051248497,
        22.586668342884625,
        22.64155263452036,
        22.696436926156228,
        22.751321217792107,
        22.80620550942815,
        22.861089801064036,
        22.91597409269986,
        22.97085838433536,
        23.02574267597175,
        23.08062696760757,
        23.135511259243096,
        23.190395550878918,
        23.245279842515302,
        23.300164134150847,
        23.355048425786418,
        23.409932717422485,
        23.464817009058944,
        23.519701300693576,
        23.574585592329928,
        23.62946988396635,
        23.68435417560226,
        23.739238467237474,
        23.794122758874376,
        23.849007050509663,
        23.9038913421455,
        23.958775633780718,
        24.013659925417176,
        24.068544217052978,
        24.123428508688853,
        24.178312800324544,
        24.23319709196104,
        24.28808138359684,
        24.342965675232637,
        24.39784996686782,
        24.452734258504243,
        24.507618550140702,
        24.56250284177541,
        24.617387133411135,
        24.672271425047594,
        24.72715571668343,
        24.782040008319267,
        24.836924299955072,
        24.8918085915908,
        24.946692883227296,
        25.001577174862476,
        25.056461466498966,
        25.111345758134696,
        25.166230049770604,
        25.221114341406377,
        25.275998633042214,
        25.330882924678082,
        25.38576721631385,
        25.44065150794976,
        25.495535799586072,
        25.550420091221326,
        25.605304382857167,
        25.660188674493654,
        25.715072966128766,
        25.76995725776519,
        25.82484154940099,
        25.879725841036787,
        25.934610132673246,
        25.989494424308393,
        26.044378715944305,
        26.099263007580692,
        26.154147299215982,
        26.209031590851815,
        26.263915882488202,
        26.318800174123858,
        26.373684465759837,
        26.428568757395098,
        26.483453049031585,
        26.538337340667283,
        26.593221632303084,
        26.64810592393888,
        26.7029902155752,
        26.757874507211177,
        26.812758798847014,
        26.867643090482236,
        26.92252738211858,
        26.977411673754425,
        27.03229596538971,
        27.08718025702613,
        27.14206454866241,
        27.196948840297665,
        27.251833131933537],
       'H2': [7.9755089475619405,
        8.427205439435077,
        8.878901931308219,
        9.330598423181355,
        9.78229491505449,
        10.233991406927629,
        10.685687898800765,
        11.137384390673908,
        11.589080882547039,
        12.040777374420179,
        12.492473866293318,
        12.944170358166454,
        13.395866850039594,
        13.847563341912732,
        14.299259833785866,
        14.750956325659004,
        15.202652817532142,
        15.654349309405282,
        16.10604580127842,
        16.557742293151566,
        17.009438785024695,
        17.461135276897835,
        17.912831768770967,
        18.364528260644104,
        18.81622475251725,
        19.267921244390386,
        19.719617736263515,
        20.171314228136662,
        20.62301072000979,
        21.07470721188294,
        21.52640370375607,
        21.978100195629207,
        22.42979668750235,
        22.881493179375486,
        23.115304319674333,
        23.09885764828226,
        23.082410976890174,
        23.06596430549809,
        23.049517634105996,
        23.033070962713918,
        23.016624291321822,
        23.000177619929744,
        22.983730948537655,
        22.967284277145563,
        22.93543454141925,
        22.36170665773788,
        21.767334039411093,
        21.16387637759552,
        20.560418715780152,
        19.956961053964793,
        19.353503392149427,
        18.75004573033405,
        18.14658806851869,
        17.543130406703305,
        16.939672744887936,
        16.336215083072574,
        15.732757421257192,
        15.129299759441826,
        14.525842097626454,
        13.922384435811074,
        13.318926773995727,
        12.715469112180333,
        12.112011450364985,
        11.50855378854959,
        10.905096126734223,
        10.301638464918915,
        9.698180803103496,
        9.094723141288117,
        8.491265479472723,
        7.887807817657369,
        7.28435015584201,
        6.680892494026633,
        6.077434832211261,
        5.473977170395881,
        4.881812854207752,
        4.450230155683833,
        4.025629042591785,
        3.6010279294998924,
        3.205416813621762,
        3.185693810827298,
        3.1659708080331654,
        3.146247805238739,
        3.1265248024443557,
        3.106801799649934,
        3.087078796855517,
        3.067355794061091,
        3.0476327912669396,
        3.027909788472499,
        3.0081867856778643,
        2.9884637828836986,
        2.9687407800893055,
        2.9490177772948982,
        2.9292947745004674,
        2.909571771706306,
        2.8898487689119228,
        2.87012576611752,
        2.8504027633230984,
        2.830679760528696,
        2.8109567577345302,
        2.791233754940085,
        2.771510752145678,
        2.751787749351285,
        2.7320647465571333,
        2.7123417437624653,
        2.6926187409682902,
        2.6728957381736698,
        2.653172735379466,
        2.6334497325850728,
        2.613726729790917,
        2.594003726996263,
        2.574280724202088,
        2.5545577214076665,
        2.5348347186132543,
        2.5151117158188705,
        2.495388713024686,
        2.4756657102302597,
        2.455942707435881,
        2.43621970464145,
        2.4164967018470613,
        2.396773699052891,
        2.3770506962582325,
        2.357327693463816,
        2.337604690669641,
        2.317881687875475,
        2.2981586850808498,
        2.2784356822864233,
        2.258712679492021,
        2.2389896766978645,
        2.219266673903443,
        2.1995436711090455,
        2.1798206683146617,
        2.1600976655204818,
        2.140374662726051,
        2.1206516599314065,
        2.1009286571372408,
        2.0812056543428334,
        2.061482651548436,
        2.0417596487539904,
        2.022036645959853,
        2.00231364316546,
        1.9825906403710007,
        1.962867637576584,
        1.94314463478221,
        1.9234216319880393,
        1.9036986291936273,
        1.8839756263992247,
        1.8642526236047985,
        1.8445296208103628,
        1.8248066180162539,
        1.8050836152217755,
        1.7853606124272023,
        1.765637609633032,
        1.745914606838871,
        1.7261916040442078,
        1.7064686012497958,
        1.6867455984556254,
        1.6670225956611897,
        1.6472995928667775,
        1.6275765900723798,
        1.607853587278233,
        1.5881305844838163,
        1.568407581689442,
        1.548684578894741,
        1.5289615761008075,
        1.5092385733064333,
        1.4895155705117464,
        1.4697925677173533,
        1.4500695649234199,
        1.4303465621287614,
        1.4106235593341598,
        1.3909005565399422,
        1.3711775537460558,
        1.351454550950616,
        1.3317315481567202,
        1.3120085453628054,
        1.2922855425684314,
        1.2725625397734934,
        1.2528395369800762,
        1.233116534185162,
        1.2133935313907738,
        1.1936705285958453,
        1.1739475258019638,
        1.1542245230075376,
        1.134501520213173,
        1.1147785174186897,
        1.095055514624832,
        1.0753325118304058,
        1.0556095090359274,
        1.035886506241037,
        1.0161635034471506,
        0.9964405006532312,
        0.9767174978578433,
        0.9569944950634408,
        0.9372714922695214,
        0.9175484894751046,
        0.8978254866807257,
        0.8781024838863042,
        0.85837948109184,
        0.8386564782979917,
        0.8189334755030586,
        0.7992104727091819,
        0.7794874699146798,
        0.7597644671203057,
        0.7400414643259362,
        0.7203184615315195,
        0.7005954587371453,
        0.6808724559426906,
        0.6611494531482975,
        0.6414264503543734,
        0.6217034475594451,
        0.6019804447650993,
        0.5822574419711847,
        0.5625344391761757,
        0.5428114363823321,
        0.5230884335879201,
        0.5033654307934606,
        0.4836424279995792,
        0.46391942520463186,
        0.4441964224102956,
        0.42447341961634305,
        0.4047504168214857,
        0.3850274140270831,
        0.36530441123313057,
        0.345581408438638,
        0.3258584056443065,
        0.3061354028494492,
        0.28641240005553925,
        0.2666893972610751,
        0.2469663944666678,
        0.22724339167220364,
        0.20752038887825583,
        0.18779738608392904,
        0.16807438328955016,
        0.14835138049464547,
        0.12862837770067395,
        0.10890537490628087,
        0.08918237211139039,
        0.0694593693174852,
        0.04973636652354685,
        0.03001336372862795,
        0.010290360934239592],
       'Biomassa': [0.0010718368543428478,
        0.004644626368818975,
        0.008217415883294965,
        0.01179020539777105,
        0.015362994912247364,
        0.018935784426723355,
        0.022508573941199327,
        0.02608136345567533,
        0.029654152970151726,
        0.03322694248462785,
        0.036799731999103726,
        0.040372521513579805,
        0.043945311028056155,
        0.0475181005425321,
        0.05109089005700822,
        0.05466367957148411,
        0.05823646908596042,
        0.06180925860043651,
        0.06538204811491258,
        0.06895483762938852,
        0.07252762714386479,
        0.07610041665834075,
        0.079673206172817,
        0.0832459956872932,
        0.08681878520176878,
        0.09039157471624526,
        0.09396436423072153,
        0.09753715374519714,
        0.10110994325967372,
        0.10468273277414937,
        0.10825552228862576,
        0.1118283118031019,
        0.11540110131757747,
        0.11897389083205401,
        0.11961499957685014,
        0.1194862120548187,
        0.11935742453278739,
        0.11922863701075612,
        0.11909984948872479,
        0.11897106196669348,
        0.11884227444466218,
        0.11871348692263084,
        0.11858469940059953,
        0.11845591187856826,
        0.11832702530026218,
        0.11819465393279571,
        0.11799463057434602,
        0.11776483588239739,
        0.11753504119044782,
        0.11730524649849824,
        0.11707545180654864,
        0.1168456571145991,
        0.11661586242264951,
        0.11638606773069994,
        0.11615627303875033,
        0.11592647834680074,
        0.11569668365485117,
        0.11546688896290157,
        0.11523709427095201,
        0.11500729957900238,
        0.11477750488705282,
        0.11454771019510324,
        0.11431791550315366,
        0.11408812081120406,
        0.11385832611925445,
        0.11362853142730485,
        0.11339873673535532,
        0.11316894204340573,
        0.11293914735145613,
        0.11270935265950657,
        0.11247955796755696,
        0.11224976327560737,
        0.11201996858365779,
        0.11179017389170821,
        0.11154675320941437,
        0.11108612551619629,
        0.11056445844636476,
        0.1100427913765325,
        0.10946496499597412,
        0.10879142456861908,
        0.10811788414125979,
        0.10744434371390414,
        0.1067708032865499,
        0.10609726285919445,
        0.10542372243183941,
        0.10475018200448355,
        0.10407664157712367,
        0.10340310114976782,
        0.10272956072241861,
        0.10205602029505834,
        0.10138247986770389,
        0.10070893944034864,
        0.10003539901299299,
        0.0993618585856327,
        0.09868831815827886,
        0.09801477773092382,
        0.09734123730356836,
        0.09666769687621352,
        0.09599415644885323,
        0.09532061602149698,
        0.09464707559414193,
        0.09397353516678769,
        0.0932999947394276,
        0.09262645431207739,
        0.09195291388471691,
        0.0912793734573683,
        0.0906058330300066,
        0.08993229260265197,
        0.08925875217529187,
        0.08858521174794227,
        0.08791167132058159,
        0.08723813089322613,
        0.08656459046587109,
        0.08589105003851705,
        0.08521750961115596,
        0.0845439691838003,
        0.08387042875644626,
        0.08319688832909061,
        0.08252334790173617,
        0.08184980747437548,
        0.08117626704702567,
        0.08050272661967023,
        0.07982918619230973,
        0.07915564576494925,
        0.07848210533760085,
        0.0778085649102452,
        0.07713502448289015,
        0.07646148405553027,
        0.07578794362817462,
        0.07511440320081997,
        0.07444086277346593,
        0.07376732234610524,
        0.07309378191874939,
        0.07242024149139978,
        0.07174670106403949,
        0.07107316063668465,
        0.07039962020933001,
        0.06972607978197355,
        0.06905253935461426,
        0.06837899892725982,
        0.06770545849990296,
        0.06703191807254792,
        0.06635837764519407,
        0.06568483721783339,
        0.06501129679047835,
        0.0643377563631235,
        0.06366421593576785,
        0.0629906755084122,
        0.06231713508105372,
        0.06164359465369606,
        0.06097005422634947,
        0.06029651379898878,
        0.0596229733716287,
        0.058949432944278284,
        0.058275892516923035,
        0.05760235208956275,
        0.056928811662206695,
        0.05625527123485165,
        0.0555817308074968,
        0.05490819038013733,
        0.05423464995278228,
        0.053561109525427836,
        0.05288756909807682,
        0.05221402867071069,
        0.05154048824335685,
        0.050866947816006036,
        0.05019340738865159,
        0.049519866961285464,
        0.048846326533935454,
        0.04817278610658786,
        0.04749924567922536,
        0.04682570525186124,
        0.04615216482452534,
        0.04547862439716042,
        0.044805083969795295,
        0.044131543542441254,
        0.043458003115095276,
        0.042784462687719675,
        0.042110922260375105,
        0.04143738183301986,
        0.04076384140567468,
        0.04009030097831057,
        0.03941676055095512,
        0.038743220123601686,
        0.03806967969624442,
        0.03739613926888071,
        0.03672259884152486,
        0.03604905841416759,
        0.03537551798682322,
        0.034701977559458703,
        0.034028437132093185,
        0.033354896704759295,
        0.03268135627740465,
        0.032007815850039124,
        0.031334275422683674,
        0.030660734995329834,
        0.029987194567974385,
        0.02931365414061712,
        0.028640113713254416,
        0.027966573285908236,
        0.027293032858544522,
        0.02661949243118585,
        0.025945952003832616,
        0.025272411576479182,
        0.02459887114912373,
        0.02392533072176949,
        0.02325179029441303,
        0.022578249867058184,
        0.021904709439692863,
        0.021231169012347284,
        0.020557628584994454,
        0.019884088157628727,
        0.019210547730280733,
        0.018537007302917827,
        0.017863466875562378,
        0.017189926448205717,
        0.016516386020841604,
        0.015842845593495424,
        0.015169305166142994,
        0.014495764738776059,
        0.013822224311433304,
        0.013148683884078458,
        0.012475143456711522,
        0.011801603029353855,
        0.011128062602001226,
        0.010454522174658268,
        0.009780981747292744,
        0.009107441319936287,
        0.00843390089258144,
        0.007760360465224177,
        0.007086820037857646,
        0.00641327961050562,
        0.005739739183151782,
        0.005066198755806809,
        0.004392658328439471,
        0.0037191179010850283,
        0.00304557747374066,
        0.0023720370463753367,
        0.001698496619010014,
        0.0010249561916644365,
        0.0003514157643101952]}
      [14]:
      NADH H2 Biomassa
      0 3.990261 7.975509 0.001072
      1 4.224465 8.427205 0.004645
      2 4.458670 8.878902 0.008217
      3 4.692874 9.330598 0.011790
      4 4.927078 9.782295 0.015363
      ... ... ... ...
      236 27.032296 0.089182 0.003046
      237 27.087180 0.069459 0.002372
      238 27.142065 0.049736 0.001698
      239 27.196949 0.030013 0.001025
      240 27.251833 0.010290 0.000351

      241 rows × 3 columns

      Read LP format model from file /tmp/tmp9p21pvv2.lp
      Reading time = 0.00 seconds
      : 310 rows, 1022 columns, 4870 nonzeros
      
      [28]:
      Biomassa NADH
      SA 0.617 28.3100
      SAn 0.103 18.5300
      M 26.070 0.0102
      Notebook
      Python 3 (ipykernel)
      Kernel status: Idle
        [1]:
        import pandas as pd
        import matplotlib.pyplot as plt
        from sklearn.preprocessing import MinMaxScaler, StandardScaler
        [11]:
        df = pd.read_csv('Final_Data.csv')
        [49]:
        df
        [49]:
        GLCptspp_fw PDH_fw PPC_fw CS_fw ACONTa_fw ACONTa_bw ACONTb_fw ACONTb_bw ICDHyr_fw ICDHyr_bw AKGDH_fw SUCOAS_fw SUCOAS_bw FUM_fw FUM_bw MDH_fw MDH_bw Produção de NADH Biomassa
        0 10.562660 1.216188 1.404998 0.483726 3.557768 3.074042 1.025892 0.542166 1.232227 1.232227 0.00000 1.478769 1.478769 0.741057 1.224783 0.000000 0.000000 16.679557 0.000000
        1 9.670392 0.173741 2.871062 0.360367 0.867981 0.507615 0.360367 0.000000 0.360367 0.000000 0.09218 0.492923 0.582421 1.852641 1.849019 2.331004 4.195807 17.698335 0.005113
        2 9.967815 1.389929 3.604094 1.183804 3.489335 2.305531 1.725970 0.542166 1.750182 0.566378 0.00000 2.454197 2.437544 1.131901 1.109411 0.932402 0.932402 19.835517 0.031742
        3 11.157505 0.173741 2.504546 1.636492 3.173513 1.537021 3.805157 2.168665 1.798605 1.798605 0.00000 0.000000 0.000000 0.370528 0.608418 2.331004 0.932402 19.719451 0.000000
        4 10.860082 0.694965 3.604094 0.447332 0.483726 0.036394 0.989498 0.542166 0.665849 0.603791 0.00000 0.030401 0.000000 2.259878 2.218822 2.331004 4.195807 22.306992 0.057947
        ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ...
        999995 10.860082 0.000000 0.671967 0.000000 0.000000 0.000000 3.352469 3.352469 0.099471 0.099471 0.00000 0.487509 0.487509 0.369804 0.369804 1.864803 2.536770 17.204439 0.000000
        999996 8.480702 0.694965 2.138030 0.229919 2.151195 1.921276 1.725970 1.496051 1.798605 1.798605 0.00000 2.437544 2.437544 1.852641 2.548761 0.000000 0.466201 13.985866 0.000000
        999997 8.778125 0.521223 3.237578 0.316884 1.469650 1.152766 1.725970 1.409086 0.883262 0.566378 0.00000 1.478769 1.445357 1.524338 1.479215 0.045123 0.000000 18.011220 0.063688
        999998 9.967815 0.521223 1.771514 0.000000 1.636492 1.636492 1.084333 1.084333 1.232227 1.232227 0.00000 1.462527 1.462527 1.479215 1.479215 0.932402 2.703916 16.168368 0.000000
        999999 10.562660 1.216188 0.671967 0.273401 2.194677 1.921276 3.352469 3.079067 0.556591 0.283189 0.00000 2.953313 2.925053 0.000000 0.000000 1.864803 1.864803 20.419944 0.053867

        1000000 rows × 19 columns

        [50]:
        df_geral = df.copy()
        df_restrito = df.copy()

        df_restrito = df_restrito.loc[(df['Biomassa']>=0.05)&(df['Produção de NADH'] >=24),]

        df_geral.drop(index=df_restrito.index,inplace=True)
        df_geral['Label'] = ['Geral' for i in range(len(df_geral))]
        [51]:
        GLCptspp_fw PDH_fw PPC_fw CS_fw ACONTa_fw ACONTa_bw ACONTb_fw ACONTb_bw ICDHyr_fw ICDHyr_bw AKGDH_fw SUCOAS_fw SUCOAS_bw FUM_fw FUM_bw MDH_fw MDH_bw Produção de NADH Biomassa Label
        0 10.562660 1.216188 1.404998 0.483726 3.557768 3.074042 1.025892 0.542166 1.232227 1.232227 0.00000 1.478769 1.478769 0.741057 1.224783 0.000000 0.000000 16.679557 0.000000 Geral
        1 9.670392 0.173741 2.871062 0.360367 0.867981 0.507615 0.360367 0.000000 0.360367 0.000000 0.09218 0.492923 0.582421 1.852641 1.849019 2.331004 4.195807 17.698335 0.005113 Geral
        2 9.967815 1.389929 3.604094 1.183804 3.489335 2.305531 1.725970 0.542166 1.750182 0.566378 0.00000 2.454197 2.437544 1.131901 1.109411 0.932402 0.932402 19.835517 0.031742 Geral
        3 11.157505 0.173741 2.504546 1.636492 3.173513 1.537021 3.805157 2.168665 1.798605 1.798605 0.00000 0.000000 0.000000 0.370528 0.608418 2.331004 0.932402 19.719451 0.000000 Geral
        4 10.860082 0.694965 3.604094 0.447332 0.483726 0.036394 0.989498 0.542166 0.665849 0.603791 0.00000 0.030401 0.000000 2.259878 2.218822 2.331004 4.195807 22.306992 0.057947 Geral
        ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ...
        999995 10.860082 0.000000 0.671967 0.000000 0.000000 0.000000 3.352469 3.352469 0.099471 0.099471 0.00000 0.487509 0.487509 0.369804 0.369804 1.864803 2.536770 17.204439 0.000000 Geral
        999996 8.480702 0.694965 2.138030 0.229919 2.151195 1.921276 1.725970 1.496051 1.798605 1.798605 0.00000 2.437544 2.437544 1.852641 2.548761 0.000000 0.466201 13.985866 0.000000 Geral
        999997 8.778125 0.521223 3.237578 0.316884 1.469650 1.152766 1.725970 1.409086 0.883262 0.566378 0.00000 1.478769 1.445357 1.524338 1.479215 0.045123 0.000000 18.011220 0.063688 Geral
        999998 9.967815 0.521223 1.771514 0.000000 1.636492 1.636492 1.084333 1.084333 1.232227 1.232227 0.00000 1.462527 1.462527 1.479215 1.479215 0.932402 2.703916 16.168368 0.000000 Geral
        999999 10.562660 1.216188 0.671967 0.273401 2.194677 1.921276 3.352469 3.079067 0.556591 0.283189 0.00000 2.953313 2.925053 0.000000 0.000000 1.864803 1.864803 20.419944 0.053867 Geral

        999751 rows × 20 columns

        [52]:
        GLCptspp_fw PDH_fw PPC_fw CS_fw ACONTa_fw ACONTa_bw ACONTb_fw ACONTb_bw ICDHyr_fw ICDHyr_bw AKGDH_fw SUCOAS_fw SUCOAS_bw FUM_fw FUM_bw MDH_fw MDH_bw Produção de NADH Biomassa
        682 10.265237 1.563670 2.871062 0.142954 0.527209 0.384255 1.183804 1.040850 0.426143 0.283189 0.000000 0.519631 0.487509 0.370528 0.369804 4.195807 4.195807 24.417125 0.061228
        1251 10.860082 1.389929 3.604094 0.360367 0.360367 0.000000 2.810302 2.449936 0.643556 0.283189 0.000000 1.971692 1.945435 0.035460 0.000000 4.195807 4.195807 24.657655 0.050049
        11359 11.157505 1.042447 3.237578 0.490815 0.490815 0.000000 2.117313 1.626499 1.340382 0.849567 0.061453 0.492923 0.526793 0.407055 0.369804 4.195807 4.195807 24.592242 0.052577
        11831 10.562660 1.389929 2.871062 0.309687 0.483726 0.174040 0.851853 0.542166 0.592876 0.283189 0.245814 0.000000 0.214524 1.151667 1.109411 3.729606 3.729606 24.214517 0.059641
        13024 10.562660 1.563670 3.604094 0.099471 0.099471 0.000000 1.183804 1.084333 0.949038 0.849567 0.000000 0.518868 0.487509 0.412153 0.369804 3.263405 3.263405 24.057084 0.059772
        ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ...
        967341 11.157505 1.216188 3.604094 0.447332 0.483726 0.036394 1.531665 1.084333 0.730521 0.283189 0.153634 0.492923 0.614988 0.412436 0.369804 2.797205 3.263405 24.006515 0.060172
        973918 10.562660 1.042447 3.237578 0.192313 0.960823 0.768510 0.192313 0.000000 0.192313 0.000000 0.122907 0.492923 0.581830 0.785524 0.739607 3.729606 4.195807 24.080630 0.064808
        977070 10.265237 1.563670 3.237578 0.099471 1.252237 1.152766 0.099471 0.000000 0.949038 0.849567 0.000000 0.518514 0.487509 0.000000 0.000000 4.195807 4.195807 24.469771 0.059098
        978778 11.157505 1.389929 3.604094 0.338586 0.867981 0.529395 1.965085 1.626499 0.338586 0.000000 0.276540 0.492923 0.739069 0.041047 0.000000 2.838252 2.797205 24.245067 0.057935
        988765 10.265237 1.563670 2.504546 0.316884 0.701139 0.384255 0.316884 0.000000 0.600073 0.283189 0.245814 0.000000 0.213570 0.783151 0.739607 3.773150 3.729606 24.031348 0.061459

        249 rows × 19 columns

        [44]:
        GLCptspp_fw PDH_fw PPC_fw CS_fw ACONTa_fw ACONTa_bw ACONTb_fw ACONTb_bw ICDHyr_fw ICDHyr_bw AKGDH_fw SUCOAS_fw SUCOAS_bw FUM_fw FUM_bw MDH_fw MDH_bw Produção de NADH Biomassa Label
        0 10.562660 1.216188 1.404998 0.483726 3.557768 3.074042 1.025892 0.542166 1.232227 1.232227 0.000000 1.478769 1.478769 0.741057 1.224783 0.000000 0.000000 16.679557 0.00000 Geral
        1 9.670392 0.173741 2.871062 0.360367 0.867981 0.507615 0.360367 0.000000 0.360367 0.000000 0.092180 0.492923 0.582421 1.852641 1.849019 2.331004 4.195807 17.698335 0.00511 Geral
        2 9.967815 1.389929 3.604094 1.183804 3.489335 2.305531 1.725970 0.542166 1.750182 0.566378 0.000000 2.454197 2.437544 1.131901 1.109411 0.932402 0.932402 19.835517 0.03174 Geral
        4 10.860082 0.694965 3.604094 0.447332 0.483726 0.036394 0.989498 0.542166 0.665849 0.603791 0.000000 0.030401 0.000000 2.259878 2.218822 2.331004 4.195807 22.306992 0.05795 Geral
        5 8.480702 1.389929 2.504546 0.316884 0.316884 0.000000 0.316884 0.000000 1.232227 1.132756 0.030727 0.492923 0.492814 1.520858 1.479215 1.398602 1.398602 19.374862 0.05878 Geral
        ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ...
        991797 10.265237 1.216188 2.138030 1.636492 3.173513 1.537021 1.636492 0.000000 2.081794 1.415945 0.000000 0.006332 0.000000 0.748159 0.739607 2.843997 1.864803 20.662284 0.01207 Geral
        993694 8.778125 0.347482 1.038482 0.099471 0.483726 0.384255 0.641637 0.542166 1.232227 1.132756 0.000857 0.047451 0.000000 0.000000 0.669568 0.262834 0.932402 18.154520 0.09208 Geral
        996912 10.265237 1.042447 3.604094 1.725970 2.110225 0.384255 2.810302 1.084333 0.382660 0.381076 0.000000 0.975794 0.975018 0.001048 0.000000 0.000000 0.000000 17.914036 0.00148 Geral
        997936 10.562660 1.042447 2.504546 1.636492 3.557768 1.921276 1.636492 0.000000 0.949038 0.566378 0.000000 0.978073 0.975018 1.113537 1.109411 3.729606 3.263405 21.522768 0.00582 Geral
        999437 9.967815 1.216188 3.604094 2.020747 3.557768 1.537021 4.731578 2.710831 2.587125 0.566378 0.215087 0.492923 0.707136 1.480396 1.479215 2.797205 2.797205 20.475337 0.00167 Geral

        9079 rows × 20 columns

        [45]:
        GLCptspp_fw PDH_fw PPC_fw CS_fw ACONTa_fw ACONTa_bw ACONTb_fw ACONTb_bw ICDHyr_fw ICDHyr_bw AKGDH_fw SUCOAS_fw SUCOAS_bw FUM_fw FUM_bw MDH_fw MDH_bw Produção de NADH Biomassa Label
        682 10.265237 1.563670 2.871062 0.142954 0.527209 0.384255 1.183804 1.040850 0.426143 0.283189 0.000000 0.519631 0.487509 0.370528 0.369804 4.195807 4.195807 24.42 0.061228 Melhores
        1251 10.860082 1.389929 3.604094 0.360367 0.360367 0.000000 2.810302 2.449936 0.643556 0.283189 0.000000 1.971692 1.945435 0.035460 0.000000 4.195807 4.195807 24.66 0.050049 Melhores
        11359 11.157505 1.042447 3.237578 0.490815 0.490815 0.000000 2.117313 1.626499 1.340382 0.849567 0.061453 0.492923 0.526793 0.407055 0.369804 4.195807 4.195807 24.59 0.052577 Melhores
        11831 10.562660 1.389929 2.871062 0.309687 0.483726 0.174040 0.851853 0.542166 0.592876 0.283189 0.245814 0.000000 0.214524 1.151667 1.109411 3.729606 3.729606 24.21 0.059641 Melhores
        13024 10.562660 1.563670 3.604094 0.099471 0.099471 0.000000 1.183804 1.084333 0.949038 0.849567 0.000000 0.518868 0.487509 0.412153 0.369804 3.263405 3.263405 24.06 0.059772 Melhores
        ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ...
        875919 10.265237 0.868706 3.237578 0.099471 0.867981 0.768510 0.099471 0.000000 0.099471 0.000000 0.000000 0.037844 0.000000 0.000000 0.000000 4.195807 4.195807 24.38 0.072134 Melhores
        918573 10.860082 1.389929 3.237578 0.447332 0.447332 0.000000 3.352469 2.905137 0.730521 0.283189 0.000000 0.027327 0.000000 0.741057 0.749979 4.186884 4.195807 24.61 0.052087 Melhores
        945138 11.157505 1.042447 3.237578 0.099471 0.099471 0.000000 0.099471 0.000000 0.382660 0.283189 0.000000 1.980634 1.950035 0.370528 0.370528 4.195807 4.195807 24.62 0.058324 Melhores
        958074 11.157505 1.042447 3.604094 0.447332 1.600098 1.152766 0.641637 0.194305 0.730521 0.283189 0.000000 0.031451 0.000000 0.412277 0.369804 3.305879 3.263405 24.25 0.059948 Melhores
        958825 10.562660 1.042447 3.604094 0.192834 0.192834 0.000000 0.735000 0.542166 0.476023 0.283189 0.122907 0.492923 0.581575 0.046261 0.000000 4.195807 4.195807 24.84 0.065294 Melhores

        78 rows × 20 columns

        <ggplot: (640 x 480)>
        
        [46]:
        GLCptspp_fw PDH_fw PPC_fw CS_fw ACONTa_fw ACONTa_bw ACONTb_fw ACONTb_bw ICDHyr_fw ICDHyr_bw AKGDH_fw SUCOAS_fw SUCOAS_bw FUM_fw FUM_bw MDH_fw MDH_bw Produção de NADH Biomassa Label
        0 10.562660 1.216188 1.404998 0.483726 3.557768 3.074042 1.025892 0.542166 1.232227 1.232227 0.000000 1.478769 1.478769 0.741057 1.224783 0.000000 0.000000 16.679557 0.000000 Geral
        1 9.670392 0.173741 2.871062 0.360367 0.867981 0.507615 0.360367 0.000000 0.360367 0.000000 0.092180 0.492923 0.582421 1.852641 1.849019 2.331004 4.195807 17.698335 0.005110 Geral
        2 9.967815 1.389929 3.604094 1.183804 3.489335 2.305531 1.725970 0.542166 1.750182 0.566378 0.000000 2.454197 2.437544 1.131901 1.109411 0.932402 0.932402 19.835517 0.031740 Geral
        4 10.860082 0.694965 3.604094 0.447332 0.483726 0.036394 0.989498 0.542166 0.665849 0.603791 0.000000 0.030401 0.000000 2.259878 2.218822 2.331004 4.195807 22.306992 0.057950 Geral
        5 8.480702 1.389929 2.504546 0.316884 0.316884 0.000000 0.316884 0.000000 1.232227 1.132756 0.030727 0.492923 0.492814 1.520858 1.479215 1.398602 1.398602 19.374862 0.058780 Geral
        ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ...
        875919 10.265237 0.868706 3.237578 0.099471 0.867981 0.768510 0.099471 0.000000 0.099471 0.000000 0.000000 0.037844 0.000000 0.000000 0.000000 4.195807 4.195807 24.380000 0.072134 Melhores
        918573 10.860082 1.389929 3.237578 0.447332 0.447332 0.000000 3.352469 2.905137 0.730521 0.283189 0.000000 0.027327 0.000000 0.741057 0.749979 4.186884 4.195807 24.610000 0.052087 Melhores
        945138 11.157505 1.042447 3.237578 0.099471 0.099471 0.000000 0.099471 0.000000 0.382660 0.283189 0.000000 1.980634 1.950035 0.370528 0.370528 4.195807 4.195807 24.620000 0.058324 Melhores
        958074 11.157505 1.042447 3.604094 0.447332 1.600098 1.152766 0.641637 0.194305 0.730521 0.283189 0.000000 0.031451 0.000000 0.412277 0.369804 3.305879 3.263405 24.250000 0.059948 Melhores
        958825 10.562660 1.042447 3.604094 0.192834 0.192834 0.000000 0.735000 0.542166 0.476023 0.283189 0.122907 0.492923 0.581575 0.046261 0.000000 4.195807 4.195807 24.840000 0.065294 Melhores

        9157 rows × 20 columns

        /home/cristian/.conda/envs/me25/lib/python3.12/site-packages/plotnine/ggplot.py:630: PlotnineWarning: Saving 14 x 6 in image.
        /home/cristian/.conda/envs/me25/lib/python3.12/site-packages/plotnine/ggplot.py:631: PlotnineWarning: Filename: scatter.png
        
          [1]:
          import pandas as pd
          import matplotlib.pyplot as plt
          import numpy as np
          [2]:
          df = pd.read_csv('Dados_Gerais.csv')
          [3]:
          df.loc[(df['ano_ingresso']==2025) & (df['curso'] == 'BA'),]
          [3]:
          ano_ingresso periodo_ingresso curso nivel_curso descricao_cor_raca descricao_quota total Unnamed: 7 Unnamed: 8
          583 2025 1 BA D BRANCA Não Cotista 3 NaN NaN
          584 2025 1 BA D PARDA Não Cotista 1 NaN NaN
          585 2025 1 BA D PRETA Autodeclarado preto ou pardo 1 NaN NaN
          600 2025 1 BA M BRANCA Não Cotista 7 NaN NaN
          601 2025 1 BA M INDÍGENA Não Cotista 1 NaN NaN
          602 2025 1 BA M PARDA Autodeclarado preto ou pardo 1 NaN NaN
          603 2025 1 BA M PARDA Não Cotista 2 NaN NaN
          604 2025 1 BA M PRETA Autodeclarado preto ou pardo 1 NaN NaN
          621 2025 2 BA D BRANCA Não Cotista 1 NaN NaN
          633 2025 2 BA M BRANCA Não Cotista 1 NaN NaN
          [4]:
          df
          [4]:
          ano_ingresso periodo_ingresso curso nivel_curso descricao_cor_raca descricao_quota total Unnamed: 7 Unnamed: 8
          0 2015 1 BFM D BRANCA Não Cotista 7 NaN NaN
          1 2015 1 BFM D NAO DECLARADO Não Cotista 8 NaN NaN
          2 2015 1 BCE D BRANCA Não Cotista 4 NaN NaN
          3 2015 1 BCE D NAO DECLARADO Não Cotista 3 NaN NaN
          4 2015 1 GBM D BRANCA Não Cotista 9 NaN NaN
          ... ... ... ... ... ... ... ... ... ...
          631 2025 2 BV M PARDA Autodeclarado preto ou pardo 1 NaN NaN
          632 2025 2 BV M PARDA Não Cotista 1 NaN NaN
          633 2025 2 BA M BRANCA Não Cotista 1 NaN NaN
          634 2025 2 BMM M BRANCA Não Cotista 7 NaN NaN
          635 2025 2 BMM M PARDA Não Cotista 1 NaN NaN

          636 rows × 9 columns

          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 13 8 0 0 1 22
          2016 14 5 2 0 0 21
          2017 23 5 3 0 0 31
          2018 17 5 4 0 1 27
          2019 15 0 2 0 2 19
          2020 9 0 7 0 0 16
          2021 13 2 1 0 0 16
          2022 9 0 4 0 0 13
          2023 4 1 3 0 0 8
          2024 7 0 2 0 1 10
          2025 12 0 6 1 0 19
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015.1 8 4 0 0 0 12
          2015.2 5 4 0 0 1 10
          2016.1 9 3 1 0 0 13
          2016.2 5 2 1 0 0 8
          2017.1 12 2 1 0 0 15
          2017.2 11 3 2 0 0 16
          2018.1 16 5 3 0 1 25
          2018.2 1 0 1 0 0 2
          2019.1 11 0 0 0 1 12
          2019.2 4 0 2 0 1 7
          2020.1 7 0 5 0 0 12
          2020.2 2 0 2 0 0 4
          2021.1 13 2 1 0 0 16
          2021.2 0 0 0 0 0 0
          2022.1 3 0 4 0 0 7
          2022.2 6 0 0 0 0 6
          2023.1 4 1 2 0 0 7
          2023.2 0 0 1 0 0 1
          2024.1 6 0 2 0 1 9
          2024.2 1 0 0 0 0 1
          2025.1 10 0 6 1 0 17
          2025.2 2 0 0 0 0 2
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 3 15 0 0 0 18
          2016 12 9 5 1 1 28
          2017 15 8 2 0 0 25
          2018 9 3 1 1 0 14
          2019 19 1 3 0 1 24
          2020 4 4 3 0 0 11
          2021 12 7 6 0 0 25
          2022 11 1 4 0 0 16
          2023 4 4 5 0 1 14
          2024 13 3 5 1 0 22
          2025 15 1 9 0 1 26
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015.1 3 7 0 0 0 10
          2015.2 0 8 0 0 0 8
          2016.1 8 6 4 1 1 20
          2016.2 4 3 1 0 0 8
          2017.1 14 8 2 0 0 24
          2017.2 1 0 0 0 0 1
          2018.1 7 2 1 0 0 10
          2018.2 2 1 0 1 0 4
          2019.1 12 0 1 0 1 14
          2019.2 7 1 2 0 0 10
          2020.1 4 4 3 0 0 11
          2020.2 0 0 0 0 0 0
          2021.1 5 3 3 0 0 11
          2021.2 7 4 3 0 0 14
          2022.1 9 1 1 0 0 11
          2022.2 2 0 3 0 0 5
          2023.1 1 0 4 0 1 6
          2023.2 3 4 1 0 0 8
          2024.1 6 2 2 1 0 11
          2024.2 7 1 3 0 0 11
          2025.1 11 1 6 0 1 19
          2025.2 4 0 3 0 0 7
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 30 24 7 0 2 63
          2016 23 17 8 0 2 50
          2017 37 13 10 0 2 62
          2018 45 15 11 1 3 75
          2019 40 13 12 0 1 66
          2020 38 9 12 1 1 61
          2021 27 3 17 0 1 48
          2022 35 4 6 0 0 45
          2023 24 4 12 0 1 41
          2024 33 6 6 0 0 45
          2025 37 6 21 0 1 65
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015.1 26 13 6 0 2 47
          2015.2 4 11 1 0 0 16
          2016.1 18 10 5 0 2 35
          2016.2 5 7 3 0 0 15
          2017.1 32 8 6 0 1 47
          2017.2 5 5 4 0 1 15
          2018.1 33 11 8 1 1 54
          2018.2 12 4 3 0 2 21
          2019.1 31 8 11 0 0 50
          2019.2 9 5 1 0 1 16
          2020.1 22 7 6 1 1 37
          2020.2 15 2 6 0 0 23
          2021.1 16 3 12 0 1 32
          2021.2 11 0 5 0 0 16
          2022.1 20 4 2 0 0 26
          2022.2 15 0 4 0 0 19
          2023.1 14 4 6 0 1 25
          2023.2 10 0 6 0 0 16
          2024.1 18 4 2 0 0 24
          2024.2 15 2 4 0 0 21
          2025.1 24 3 15 0 1 43
          2025.2 13 3 6 0 0 22
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 30 24 7 0 2 63
          2016 23 17 8 0 2 50
          2017 37 13 10 0 2 62
          2018 45 15 11 1 3 75
          2019 40 13 12 0 1 66
          2020 38 9 12 1 1 61
          2021 27 3 17 0 1 48
          2022 35 4 6 0 0 45
          2023 24 4 12 0 1 41
          2024 33 6 6 0 0 45
          2025 37 6 21 0 1 65
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015.1 26 13 6 0 2 47
          2015.2 4 11 1 0 0 16
          2016.1 18 10 5 0 2 35
          2016.2 5 7 3 0 0 15
          2017.1 32 8 6 0 1 47
          2017.2 5 5 4 0 1 15
          2018.1 33 11 8 1 1 54
          2018.2 12 4 3 0 2 21
          2019.1 31 8 11 0 0 50
          2019.2 9 5 1 0 1 16
          2020.1 22 7 6 1 1 37
          2020.2 15 2 6 0 0 23
          2021.1 16 3 12 0 1 32
          2021.2 11 0 5 0 0 16
          2022.1 20 4 2 0 0 26
          2022.2 15 0 4 0 0 19
          2023.1 14 4 6 0 1 25
          2023.2 9 0 6 0 0 15
          2024.1 18 4 2 0 0 24
          2024.2 15 2 4 0 0 21
          2025.1 24 3 15 0 1 43
          2025.2 13 3 6 0 0 22
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2022 106 26 21 0 2 155
          2023 18 2 10 1 0 31
          2024 31 5 9 0 2 47
          2025 46 2 13 0 2 63
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 16 16 3 0 0 35
          2016 17 7 3 0 0 27
          2017 16 3 4 0 0 23
          2018 15 3 6 0 0 24
          2019 17 7 4 0 0 28
          2020 18 4 1 0 0 23
          2021 8 4 4 0 0 16
          2022 12 0 1 0 0 13
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 21 11 4 0 0 36
          2016 10 12 4 0 0 26
          2017 19 5 3 0 0 27
          2018 20 6 3 0 1 30
          2019 21 4 2 0 1 28
          2020 19 4 6 0 1 30
          2021 19 3 5 0 1 28
          2022 7 0 2 0 0 9
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 10 10 1 0 1 22
          2016 13 5 1 0 0 19
          2017 16 5 1 0 0 22
          2018 12 2 3 0 0 17
          2019 13 4 9 0 0 26
          2020 11 1 3 0 0 15
          2021 19 0 6 0 1 26
          2022 13 2 2 0 0 17
          2023 15 2 7 0 0 24
          2024 17 2 6 0 0 25
          2025 19 0 5 0 0 24
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015.1 6 9 1 0 1 17
          2015.2 4 1 0 0 0 5
          2016.1 4 3 1 0 0 8
          2016.2 9 2 0 0 0 11
          2017.1 8 2 1 0 0 11
          2017.2 8 3 0 0 0 11
          2018.1 9 2 1 0 0 12
          2018.2 3 0 2 0 0 5
          2019.1 10 2 7 0 0 19
          2019.2 3 2 2 0 0 7
          2020.1 10 1 3 0 0 14
          2020.2 1 0 0 0 0 1
          2021.1 14 0 4 0 1 19
          2021.2 5 0 2 0 0 7
          2022.1 11 2 2 0 0 15
          2022.2 2 0 0 0 0 2
          2023.1 9 2 7 0 0 18
          2023.2 6 0 0 0 0 6
          2024.1 16 2 6 0 0 24
          2024.2 1 0 0 0 0 1
          2025.1 17 0 2 0 0 19
          2025.2 2 0 3 0 0 5
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2017 2 18 0 0 0 20
          2018 11 6 3 0 0 20
          2020 15 2 2 0 1 20
          2022 13 5 2 0 0 20
          2023 13 2 5 0 0 20
          2024 10 1 7 0 1 19
          2025 12 1 2 0 0 15
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015.1 0 0 0 0 0 0
          2015.2 0 0 0 0 0 0
          2016.1 0 0 0 0 0 0
          2016.2 0 0 0 0 0 0
          2017.1 0 0 0 0 0 0
          2017.2 2 18 0 0 0 20
          2018.1 0 0 0 0 0 0
          2018.2 11 6 3 0 0 20
          2019.1 0 0 0 0 0 0
          2019.2 0 0 0 0 0 0
          2020.1 15 2 2 0 1 20
          2020.2 0 0 0 0 0 0
          2021.1 0 0 0 0 0 0
          2021.2 0 0 0 0 0 0
          2022.1 0 0 0 0 0 0
          2022.2 0 0 0 0 0 0
          2023.1 0 0 0 0 0 0
          2023.2 13 2 5 0 0 20
          2024.1 10 1 7 0 1 19
          2024.2 0 0 0 0 0 0
          2025.1 12 1 2 0 0 15
          2025.2 0 0 0 0 0 0
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2017 2 18 0 0 0 20
          2018 11 6 3 0 0 20
          2020 15 2 2 0 1 20
          2022 13 5 2 0 0 20
          2023 13 2 5 0 0 20
          2024 10 1 7 0 1 19
          2025 12 1 2 0 0 15
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015.1 0 0 0 0 0 0
          2015.2 0 0 0 0 0 0
          2016.1 0 0 0 0 0 0
          2016.2 0 0 0 0 0 0
          2017.1 0 0 0 0 0 0
          2017.2 2 18 0 0 0 20
          2018.1 0 0 0 0 0 0
          2018.2 11 6 3 0 0 20
          2019.1 0 0 0 0 0 0
          2019.2 0 0 0 0 0 0
          2020.1 15 2 2 0 1 20
          2020.2 0 0 0 0 0 0
          2021.1 0 0 0 0 0 0
          2021.2 0 0 0 0 0 0
          2022.1 0 0 0 0 0 0
          2022.2 0 0 0 0 0 0
          2023.1 0 0 0 0 0 0
          2023.2 0 0 0 0 0 0
          2024.1 10 1 7 0 1 19
          2024.2 0 0 0 0 0 0
          2025.1 12 1 2 0 0 15
          2025.2 0 0 0 0 0 0
          [32]:
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 NaN NaN NaN NaN NaN NaN
          2016 NaN NaN NaN NaN NaN NaN
          2017 NaN NaN NaN NaN NaN NaN
          2018 NaN NaN NaN NaN NaN NaN
          2019 NaN NaN NaN NaN NaN NaN
          2020 NaN NaN NaN NaN NaN NaN
          2021 NaN NaN NaN NaN NaN NaN
          2022 206.0 38.0 42.0 0.0 2.0 288.0
          2023 NaN NaN NaN NaN NaN NaN
          2024 NaN NaN NaN NaN NaN NaN
          2025 NaN NaN NaN NaN NaN NaN
          [20]:
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015.1 71 49 10 0 3 133
          2015.2 22 35 5 0 1 63
          2016.1 58 34 16 1 3 112
          2016.2 31 21 7 0 0 59
          2017.1 91 25 16 0 1 133
          2017.2 37 32 7 0 1 77
          2018.1 87 25 20 1 2 135
          2018.2 42 15 11 1 3 72
          2019.1 84 17 22 0 3 126
          2019.2 41 12 10 0 2 65
          2020.1 79 19 25 1 2 126
          2020.2 34 5 9 0 1 49
          2021.1 65 14 28 0 3 110
          2021.2 33 5 11 0 0 49
          2022.1 62 7 12 0 0 81
          2022.2 131 26 28 0 2 187
          2023.1 41 7 22 1 2 73
          2023.2 37 8 20 0 0 65
          2024.1 83 13 22 1 4 123
          2024.2 28 4 13 0 0 45
          2025.1 110 6 40 1 4 161
          2025.2 31 4 16 0 0 51
          [43]:
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015.1 53.383459 49 7.518797 0 3 133
          2015.2 34.920635 35 7.936508 0 1 63
          2016.1 51.785714 34 14.285714 1 3 112
          2016.2 52.542373 21 11.864407 0 0 59
          2017.1 68.421053 25 12.030075 0 1 133
          2017.2 48.051948 32 9.090909 0 1 77
          2018.1 64.444444 25 14.814815 1 2 135
          2018.2 58.333333 15 15.277778 1 3 72
          2019.1 66.666667 17 17.460317 0 3 126
          2019.2 63.076923 12 15.384615 0 2 65
          2020.1 62.698413 19 19.841270 1 2 126
          2020.2 69.387755 5 18.367347 0 1 49
          2021.1 59.090909 14 25.454545 0 3 110
          2021.2 67.346939 5 22.448980 0 0 49
          2022.1 76.543210 7 14.814815 0 0 81
          2022.2 70.053476 26 14.973262 0 2 187
          2023.1 56.164384 7 30.136986 1 2 73
          2023.2 52.272727 6 34.090909 0 0 44
          2024.1 67.479675 13 17.886179 1 4 123
          2024.2 62.222222 4 28.888889 0 0 45
          2025.1 68.322981 6 24.844720 1 4 161
          2025.2 60.784314 4 31.372549 0 0 51
          [10]:
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 57 16 8 0 3 84
          2016 60 16 12 1 3 92
          2017 78 32 12 0 0 122
          2018 75 17 18 0 4 114
          2019 61 13 11 0 4 89
          2020 54 11 18 0 1 84
          2021 43 9 18 0 0 70
          2022 112 15 24 0 0 151
          2023 46 8 21 1 2 78
          2024 58 6 18 0 2 84
          2025 89 2 25 1 2 119
          [49]:
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 57 16 8 0 3 68
          2016 60 16 12 1 3 76
          2017 78 32 12 0 0 90
          2018 75 17 18 0 4 97
          2019 61 13 11 0 4 76
          2020 54 11 18 0 1 73
          2021 43 9 18 0 0 61
          2022 112 15 24 0 0 136
          2023 46 8 21 1 2 70
          2024 58 6 18 0 2 78
          2025 89 2 25 1 2 117
          [58]:
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 57 16 9.523810 0 3 84
          2016 60 16 13.043478 1 3 92
          2017 78 32 9.836066 0 0 122
          2018 75 17 15.789474 0 4 114
          2019 61 13 12.359551 0 4 89
          2020 54 11 21.428571 0 1 84
          2021 43 9 25.714286 0 0 70
          2022 112 15 15.894040 0 0 151
          2023 46 8 26.923077 1 2 78
          2024 58 6 21.428571 0 2 84
          2025 89 2 21.008403 1 2 119
          [46]:
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 36 68 7 0 1 44
          2016 29 39 11 0 0 40
          2017 50 25 11 0 2 63
          2018 54 23 13 2 1 70
          2019 64 16 21 0 1 86
          2020 60 13 16 1 2 79
          2021 55 10 21 0 3 79
          2022 94 23 18 0 2 114
          2023 32 7 21 0 0 53
          2024 53 11 17 1 2 73
          2025 52 8 31 0 2 85
          [60]:
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 36 68 6.250000 0 1 112
          2016 29 39 13.924051 0 0 79
          2017 50 25 12.500000 0 2 88
          2018 54 23 13.978495 2 1 93
          2019 64 16 20.588235 0 1 102
          2020 60 13 17.391304 1 2 92
          2021 55 10 23.595506 0 3 89
          2022 94 23 13.138686 0 2 137
          2023 32 7 35.000000 0 0 60
          2024 53 11 20.238095 1 2 84
          2025 52 8 33.333333 0 2 93
          ---------------------------------------------------------------------------
          NameError                                 Traceback (most recent call last)
          Cell In[23], line 1
          ----> 1 df_geral_separado
          
          NameError: name 'df_geral_separado' is not defined
          [20]:
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 93 84 15 0 4 112
          2016 89 55 23 1 3 116
          2017 128 57 23 0 2 153
          2018 129 40 31 2 5 167
          2019 125 29 32 0 5 162
          2020 114 24 34 1 3 152
          2021 98 19 39 0 3 140
          2022 206 38 42 0 2 250
          2023 78 15 42 1 2 123
          2024 111 17 35 1 4 151
          2025 141 10 56 1 4 202
          [21]:
          BRANCA NAO DECLARADO PP INDÍGENA AMARELA Total
          2015 93 84 13.392857 0 4 112
          2016 89 55 19.827586 1 3 116
          2017 128 57 15.032680 0 2 153
          2018 129 40 18.562874 2 5 167
          2019 125 29 19.753086 0 5 162
          2020 114 24 22.368421 1 3 152
          2021 98 19 27.857143 0 3 140
          2022 206 38 16.800000 0 2 250
          2023 78 15 34.146341 1 2 123
          2024 111 17 23.178808 1 4 151
          2025 141 10 27.722772 1 4 202
          [2]:
          Inscritos
          Brancos 141
          Não Declarados 10
          Pretos e Pardos 56
          Indígenas 1
          Amarelos 4
            [1]:
            %matplotlib inline
            import matplotlib.pyplot as plt

            import cobra
            from cobra.io import load_json_model

            import straindesign as sd

            import pandas as pd
            import numpy as np

            from matplotlib.gridspec import GridSpec
            [2]:
            model = load_json_model('iCH360_h2.json')
            Set parameter Username
            Set parameter LicenseID to value 2644080
            Academic license - for non-commercial use only - expires 2026-03-29
            
            [3]:
            solution = model.optimize()
            solution
            [3]:
            Optimal solution with objective value 0.120
            fluxes reduced_costs
            NDPK5_fw 0.003234 4.228388e-18
            SHK3Dr_fw 0.045490 1.734723e-18
            NDPK6_fw 0.003132 -2.220446e-16
            NDPK8_fw 0.003132 0.000000e+00
            DHORTS_fw 0.000000 -8.574123e-03
            ... ... ...
            HYDFDN_bw 0.000000 -3.299734e-03
            PFOR_fw 5.781830 -4.336809e-19
            EX_h2_e_fw 23.127319 0.000000e+00
            H2TPP_fw 23.127319 0.000000e+00
            H2tex_fw 23.127319 0.000000e+00

            511 rows × 2 columns

            [3]:
            %matplotlib tk
            sd.plot_flux_space(model,('Biomass_fw','HYDFDN_fw','PDH_fw'),points=50);
            [4]:
            %matplotlib tk
            sd.plot_flux_space(model,('Biomass_fw','HYDFDN_fw','MDH_fw'),points=50);
            [5]:
            %matplotlib tk
            sd.plot_flux_space(model,('Biomass_fw','HYDFDN_fw','AKGDH_fw'),points=50);
            [4]:
            sd.plot_flux_space(model, ('Biomass_fw','HYDFDN_fw'));
            [6]:
            sd.plot_flux_space(model, ('Biomass_fw','EX_etoh_e_fw'));
            INFO:root:Preparing strain design computation.
            INFO:root:  Using random seed 55661
            INFO:root:  Using gurobi for solving LPs during preprocessing.
            WARNING:root:  Removing reaction bounds when larger than the cobra-threshold of 1000.
            INFO:root:  FVA to identify blocked reactions and irreversibilities.
            INFO:root:  FVA(s) to identify essential reactions.
            INFO:root:Preprocessing GPR rules (356 genes, 447 gpr rules).
            INFO:root:  Simplifyied to 190 genes and 183 gpr rules.
            INFO:root:  Extending metabolic network with gpr associations.
            INFO:root:Compressing Network (836 reactions).
            INFO:root:  Removing blocked reactions.
            INFO:root:  Translating stoichiometric coefficients to rationals.
            INFO:root:  Removing conservation relations.
            INFO:root:  Compression 1: Applying compression from EFM-tool module.
            INFO:root:  Reduced to 472 reactions.
            INFO:root:  Compression 2: Lumping parallel reactions.
            INFO:root:  Reduced to 423 reactions.
            INFO:root:  Compression 3: Applying compression from EFM-tool module.
            INFO:root:  Reduced to 411 reactions.
            INFO:root:  Compression 4: Lumping parallel reactions.
            INFO:root:  Reduced to 410 reactions.
            INFO:root:  Compression 5: Applying compression from EFM-tool module.
            INFO:root:  Last step could not reduce size further (410 reactions).
            INFO:root:  Network compression completed. (4 compression iterations)
            INFO:root:  Translating stoichiometric coefficients back to float.
            INFO:root:  FVA(s) in compressed model to identify essential reactions.
            INFO:root:Finished preprocessing:
            INFO:root:  Model size: 410 reactions, 215 metabolites
            INFO:root:  286 targetable reactions
            WARNING:root:  Removing reaction bounds when larger than the cobra-threshold of 1000.
            INFO:root:Constructing strain design MILP for solver: gurobi.
            INFO:root:  Bounding MILP.
            INFO:root:Finding optimal strain designs ...
            INFO:root:Strain design with cost 4.0: {'PFL_fw*G_b0902*pflB*R_g_b0902_and_g_b0903*R0_g_b0902_and_g_b0903_or_g_b0902_and_g_b3114*tdcE*R_g_b0902_and_g_b3114*R1_g_b0902_and_g_b0903_or_g_b0902_and_g_b3114': np.int64(-1), 'PDH_fw*aceE*aceF*R_g_b0114_and_g_b0115': np.int64(-1), 'PYRtex_bw': np.int64(-1), 'ldhA': np.int64(-1)}
            INFO:root:Finished solving strain design MILP. 
            INFO:root:1 solutions to MILP found.
            INFO:root:  Decompressing.
            INFO:root:  Preparing (reaction-)phenotype prediction of gene intervention strategies.
            INFO:root:9 solutions found.
            
            One compressed solution with cost 4.0 found and expanded to 9 solutions in the uncompressed netork.
            Example intervention set: ['-PYRtex_bw', '-ldhA', '-PFL_fw', '-PDH_fw']
            Knockout set on the reaction level: ['LDH_D_bw', 'PDH_fw', 'PYRtex_bw', 'PFL_fw', 'LDH_D_fw']
            
            [5]:
            Optimal solution with objective value 0.110
            fluxes reduced_costs
            NDPK5_fw 0.002968 1.084202e-19
            SHK3Dr_fw 0.041747 -1.734723e-18
            NDPK6_fw 0.002875 2.220446e-16
            NDPK8_fw 0.002875 -1.387779e-17
            DHORTS_fw 0.000000 -8.178398e-03
            ... ... ...
            HYDFDN_bw 0.000000 -3.147440e-03
            PFOR_fw 7.170824 8.890458e-18
            EX_h2_e_fw 28.683297 0.000000e+00
            H2TPP_fw 28.683297 0.000000e+00
            H2tex_fw 28.683297 0.000000e+00

            511 rows × 2 columns

            Set parameter Username
            Set parameter LicenseID to value 2644080
            Academic license - for non-commercial use only - expires 2026-03-29
            Biomassa: 0.10320066433006311
            Glucose consumption: 9.250127204153337
            
            Read LP format model from file /tmp/tmpr5w2s5vi.lp
            Reading time = 0.00 seconds
            : 310 rows, 1022 columns, 4870 nonzeros
            Biomassa: 0.11970908215843598
            H2: 23.127319034133066
            
            Read LP format model from file /tmp/tmpagiipum_.lp
            Reading time = 0.00 seconds
            : 310 rows, 1022 columns, 4870 nonzeros
            Biomassa: 0.10986047739887762
            H2: 28.6832967841541
            Glucose consumption: 4.834670944898108
            
            Read LP format model from file /tmp/tmp6jnt4x4i.lp
            Reading time = 0.00 seconds
            : 310 rows, 1022 columns, 4870 nonzeros
            Biomassa: None
            H2: 28.0
            
            /home/cristian/.conda/envs/me25/lib/python3.12/site-packages/cobra/util/solver.py:554: UserWarning: Solver status is 'infeasible'.
              warn(f"Solver status is '{status}'.", UserWarning)
            
              [1]:
              import cobra
              from cobra.io import load_json_model
              [2]:
              model = load_json_model('EC_iCH360.json')
              Set parameter Username
              Set parameter LicenseID to value 2644080
              Academic license - for non-commercial use only - expires 2026-03-29
              
              [3]:
              model.reactions.get_by_id('EX_o2_e_bw').bounds = (0,0)
              [4]:
              solution = model.optimize()
              solution
              [4]:
              Optimal solution with objective value 0.103
              fluxes reduced_costs
              NDPK5_fw 0.002788 1.235990e-17
              SHK3Dr_fw 0.039217 3.469447e-18
              NDPK6_fw 0.002700 2.220446e-16
              NDPK8_fw 0.002700 0.000000e+00
              DHORTS_fw 0.000000 -7.631694e-03
              ... ... ...
              3OAR100_bw 0.000000 -3.431788e-03
              3OAR180_bw 0.000000 0.000000e+00
              ETOHtrpp_bw 0.000000 0.000000e+00
              VPAMTr_bw 0.060182 0.000000e+00
              enzyme_pool_supply 0.281839 8.576399e-01

              505 rows × 2 columns

              [5]:
              model.metabolites.get_by_id('nadh_c').summary().producing_flux['flux'].sum()
              [5]:
              np.float64(18.526949822952098)
              [ ]:

                # Ajuste dos arquivos gerados

                Ajuste dos arquivos gerados¶

                [1]:
                import pandas as pd
                import matplotlib.pyplot as plt
                import numpy as np

                import plotly.express as px
                import seaborn as sns
                [2]:
                df = pd.read_csv('Final_Data.csv')
                df
                [2]:
                GLCptspp_fw PDH_fw PPC_fw CS_fw ACONTa_fw ACONTa_bw ACONTb_fw ACONTb_bw ICDHyr_fw ICDHyr_bw AKGDH_fw SUCOAS_fw SUCOAS_bw FUM_fw FUM_bw MDH_fw MDH_bw Produção de NADH Biomassa
                0 10.562660 1.216188 1.404998 0.483726 3.557768 3.074042 1.025892 0.542166 1.232227 1.232227 0.00000 1.478769 1.478769 0.741057 1.224783 0.000000 0.000000 16.679557 0.000000
                1 9.670392 0.173741 2.871062 0.360367 0.867981 0.507615 0.360367 0.000000 0.360367 0.000000 0.09218 0.492923 0.582421 1.852641 1.849019 2.331004 4.195807 17.698335 0.005113
                2 9.967815 1.389929 3.604094 1.183804 3.489335 2.305531 1.725970 0.542166 1.750182 0.566378 0.00000 2.454197 2.437544 1.131901 1.109411 0.932402 0.932402 19.835517 0.031742
                3 11.157505 0.173741 2.504546 1.636492 3.173513 1.537021 3.805157 2.168665 1.798605 1.798605 0.00000 0.000000 0.000000 0.370528 0.608418 2.331004 0.932402 19.719451 0.000000
                4 10.860082 0.694965 3.604094 0.447332 0.483726 0.036394 0.989498 0.542166 0.665849 0.603791 0.00000 0.030401 0.000000 2.259878 2.218822 2.331004 4.195807 22.306992 0.057947
                ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ...
                999995 10.860082 0.000000 0.671967 0.000000 0.000000 0.000000 3.352469 3.352469 0.099471 0.099471 0.00000 0.487509 0.487509 0.369804 0.369804 1.864803 2.536770 17.204439 0.000000
                999996 8.480702 0.694965 2.138030 0.229919 2.151195 1.921276 1.725970 1.496051 1.798605 1.798605 0.00000 2.437544 2.437544 1.852641 2.548761 0.000000 0.466201 13.985866 0.000000
                999997 8.778125 0.521223 3.237578 0.316884 1.469650 1.152766 1.725970 1.409086 0.883262 0.566378 0.00000 1.478769 1.445357 1.524338 1.479215 0.045123 0.000000 18.011220 0.063688
                999998 9.967815 0.521223 1.771514 0.000000 1.636492 1.636492 1.084333 1.084333 1.232227 1.232227 0.00000 1.462527 1.462527 1.479215 1.479215 0.932402 2.703916 16.168368 0.000000
                999999 10.562660 1.216188 0.671967 0.273401 2.194677 1.921276 3.352469 3.079067 0.556591 0.283189 0.00000 2.953313 2.925053 0.000000 0.000000 1.864803 1.864803 20.419944 0.053867

                1000000 rows × 19 columns

                [10]:
                df.loc[(df['Biomassa']>=0.05)&(df['Produção de NADH']>=24),]
                [10]:
                GLCptspp_fw PDH_fw PPC_fw CS_fw ACONTa_fw ACONTa_bw ACONTb_fw ACONTb_bw ICDHyr_fw ICDHyr_bw AKGDH_fw SUCOAS_fw SUCOAS_bw FUM_fw FUM_bw MDH_fw MDH_bw Produção de NADH Biomassa
                682 10.265237 1.563670 2.871062 0.142954 0.527209 0.384255 1.183804 1.040850 0.426143 0.283189 0.000000 0.519631 0.487509 0.370528 0.369804 4.195807 4.195807 24.417125 0.061228
                1251 10.860082 1.389929 3.604094 0.360367 0.360367 0.000000 2.810302 2.449936 0.643556 0.283189 0.000000 1.971692 1.945435 0.035460 0.000000 4.195807 4.195807 24.657655 0.050049
                11359 11.157505 1.042447 3.237578 0.490815 0.490815 0.000000 2.117313 1.626499 1.340382 0.849567 0.061453 0.492923 0.526793 0.407055 0.369804 4.195807 4.195807 24.592242 0.052577
                11831 10.562660 1.389929 2.871062 0.309687 0.483726 0.174040 0.851853 0.542166 0.592876 0.283189 0.245814 0.000000 0.214524 1.151667 1.109411 3.729606 3.729606 24.214517 0.059641
                13024 10.562660 1.563670 3.604094 0.099471 0.099471 0.000000 1.183804 1.084333 0.949038 0.849567 0.000000 0.518868 0.487509 0.412153 0.369804 3.263405 3.263405 24.057084 0.059772
                ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... ...
                967341 11.157505 1.216188 3.604094 0.447332 0.483726 0.036394 1.531665 1.084333 0.730521 0.283189 0.153634 0.492923 0.614988 0.412436 0.369804 2.797205 3.263405 24.006515 0.060172
                973918 10.562660 1.042447 3.237578 0.192313 0.960823 0.768510 0.192313 0.000000 0.192313 0.000000 0.122907 0.492923 0.581830 0.785524 0.739607 3.729606 4.195807 24.080630 0.064808
                977070 10.265237 1.563670 3.237578 0.099471 1.252237 1.152766 0.099471 0.000000 0.949038 0.849567 0.000000 0.518514 0.487509 0.000000 0.000000 4.195807 4.195807 24.469771 0.059098
                978778 11.157505 1.389929 3.604094 0.338586 0.867981 0.529395 1.965085 1.626499 0.338586 0.000000 0.276540 0.492923 0.739069 0.041047 0.000000 2.838252 2.797205 24.245067 0.057935
                988765 10.265237 1.563670 2.504546 0.316884 0.701139 0.384255 0.316884 0.000000 0.600073 0.283189 0.245814 0.000000 0.213570 0.783151 0.739607 3.773150 3.729606 24.031348 0.061459

                249 rows × 19 columns

                [2]:
                <bound method IndexOpsMixin.tolist of Index(['GLCptspp_fw', 'PDH_fw', 'PPC_fw', 'CS_fw', 'ACONTa_fw', 'ACONTa_bw',
                       'ACONTb_fw', 'ACONTb_bw', 'ICDHyr_fw', 'ICDHyr_bw', 'AKGDH_fw',
                       'SUCOAS_fw', 'SUCOAS_bw', 'FUM_fw', 'FUM_bw', 'MDH_fw', 'MDH_bw',
                       'Produção de NADH', 'Biomassa'],
                      dtype='object')>
                [4]:
                Produção de NADH Biomassa Melhores
                0 0 0 0
                1 0 0 0
                2 0 0 0
                3 0 0 0
                4 1 0 0
                ... ... ... ...
                999995 0 0 0
                999996 0 0 0
                999997 0 0 0
                999998 0 0 0
                999999 1 0 0

                1000000 rows × 3 columns

                [7]:
                Produçao de NADH Crescimento
                0 1 1
                1 0 0
                2 1 1
                3 0 0
                4 0 0
                ... ... ...
                999995 1 1
                999996 0 0
                999997 0 0
                999998 0 0
                999999 0 0

                1000000 rows × 2 columns

                [6]:
                Produçao de NADH Crescimento
                0 1 1
                1 0 0
                2 1 1
                3 0 0
                4 0 0
                ... ... ...
                999995 1 1
                999996 0 0
                999997 0 0
                999998 0 0
                999999 0 0

                1000000 rows × 2 columns

                R² Modelo NADH: 0.954452
                R² Modelo Biomassa: 0.993984
                
                Fitting 3 folds for each of 240 candidates, totalling 720 fits
                [CV 1/3] END max_depth=3, max_features=10, min_samples_leaf=1, n_estimators=100;, score=0.750 total time= 2.2min
                [CV 2/3] END max_depth=3, max_features=10, min_samples_leaf=1, n_estimators=100;, score=0.751 total time= 2.2min
                [CV 3/3] END max_depth=3, max_features=10, min_samples_leaf=1, n_estimators=100;, score=0.752 total time= 2.2min
                
                ---------------------------------------------------------------------------
                KeyboardInterrupt                         Traceback (most recent call last)
                Cell In[70], line 12
                      4 gr_space = {
                      5     'max_depth': [3,5,7,10],
                      6     'n_estimators': [100, 200, 300, 400, 500],
                      7     'max_features': [10, 20, 30 , 40],
                      8     'min_samples_leaf': [1, 2, 4]
                      9 }
                     11 grid = GridSearchCV(rf_grid, gr_space, cv = 3, scoring='accuracy', verbose = 3)
                ---> 12 model_grid = grid.fit(X_train_NADH, y_train_NADH)
                     14 print('Best hyperparameters are '+str(model_grid.best_params_))
                     15 print('Best score is: ' + str(model_grid.best_score_))
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/base.py:1389, in _fit_context.<locals>.decorator.<locals>.wrapper(estimator, *args, **kwargs)
                   1382     estimator._validate_params()
                   1384 with config_context(
                   1385     skip_parameter_validation=(
                   1386         prefer_skip_nested_validation or global_skip_validation
                   1387     )
                   1388 ):
                -> 1389     return fit_method(estimator, *args, **kwargs)
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/model_selection/_search.py:1024, in BaseSearchCV.fit(self, X, y, **params)
                   1018     results = self._format_results(
                   1019         all_candidate_params, n_splits, all_out, all_more_results
                   1020     )
                   1022     return results
                -> 1024 self._run_search(evaluate_candidates)
                   1026 # multimetric is determined here because in the case of a callable
                   1027 # self.scoring the return type is only known after calling
                   1028 first_test_score = all_out[0]["test_scores"]
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/model_selection/_search.py:1571, in GridSearchCV._run_search(self, evaluate_candidates)
                   1569 def _run_search(self, evaluate_candidates):
                   1570     """Search all candidates in param_grid"""
                -> 1571     evaluate_candidates(ParameterGrid(self.param_grid))
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/model_selection/_search.py:970, in BaseSearchCV.fit.<locals>.evaluate_candidates(candidate_params, cv, more_results)
                    962 if self.verbose > 0:
                    963     print(
                    964         "Fitting {0} folds for each of {1} candidates,"
                    965         " totalling {2} fits".format(
                    966             n_splits, n_candidates, n_candidates * n_splits
                    967         )
                    968     )
                --> 970 out = parallel(
                    971     delayed(_fit_and_score)(
                    972         clone(base_estimator),
                    973         X,
                    974         y,
                    975         train=train,
                    976         test=test,
                    977         parameters=parameters,
                    978         split_progress=(split_idx, n_splits),
                    979         candidate_progress=(cand_idx, n_candidates),
                    980         **fit_and_score_kwargs,
                    981     )
                    982     for (cand_idx, parameters), (split_idx, (train, test)) in product(
                    983         enumerate(candidate_params),
                    984         enumerate(cv.split(X, y, **routed_params.splitter.split)),
                    985     )
                    986 )
                    988 if len(out) < 1:
                    989     raise ValueError(
                    990         "No fits were performed. "
                    991         "Was the CV iterator empty? "
                    992         "Were there no candidates?"
                    993     )
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/utils/parallel.py:77, in Parallel.__call__(self, iterable)
                     72 config = get_config()
                     73 iterable_with_config = (
                     74     (_with_config(delayed_func, config), args, kwargs)
                     75     for delayed_func, args, kwargs in iterable
                     76 )
                ---> 77 return super().__call__(iterable_with_config)
                
                File ~/anaconda3/lib/python3.12/site-packages/joblib/parallel.py:1918, in Parallel.__call__(self, iterable)
                   1916     output = self._get_sequential_output(iterable)
                   1917     next(output)
                -> 1918     return output if self.return_generator else list(output)
                   1920 # Let's create an ID that uniquely identifies the current call. If the
                   1921 # call is interrupted early and that the same instance is immediately
                   1922 # re-used, this id will be used to prevent workers that were
                   1923 # concurrently finalizing a task from the previous call to run the
                   1924 # callback.
                   1925 with self._lock:
                
                File ~/anaconda3/lib/python3.12/site-packages/joblib/parallel.py:1847, in Parallel._get_sequential_output(self, iterable)
                   1845 self.n_dispatched_batches += 1
                   1846 self.n_dispatched_tasks += 1
                -> 1847 res = func(*args, **kwargs)
                   1848 self.n_completed_tasks += 1
                   1849 self.print_progress()
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/utils/parallel.py:139, in _FuncWrapper.__call__(self, *args, **kwargs)
                    137     config = {}
                    138 with config_context(**config):
                --> 139     return self.function(*args, **kwargs)
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/model_selection/_validation.py:866, in _fit_and_score(estimator, X, y, scorer, train, test, verbose, parameters, fit_params, score_params, return_train_score, return_parameters, return_n_test_samples, return_times, return_estimator, split_progress, candidate_progress, error_score)
                    864         estimator.fit(X_train, **fit_params)
                    865     else:
                --> 866         estimator.fit(X_train, y_train, **fit_params)
                    868 except Exception:
                    869     # Note fit time as time until error
                    870     fit_time = time.time() - start_time
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/base.py:1389, in _fit_context.<locals>.decorator.<locals>.wrapper(estimator, *args, **kwargs)
                   1382     estimator._validate_params()
                   1384 with config_context(
                   1385     skip_parameter_validation=(
                   1386         prefer_skip_nested_validation or global_skip_validation
                   1387     )
                   1388 ):
                -> 1389     return fit_method(estimator, *args, **kwargs)
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/ensemble/_forest.py:487, in BaseForest.fit(self, X, y, sample_weight)
                    476 trees = [
                    477     self._make_estimator(append=False, random_state=random_state)
                    478     for i in range(n_more_estimators)
                    479 ]
                    481 # Parallel loop: we prefer the threading backend as the Cython code
                    482 # for fitting the trees is internally releasing the Python GIL
                    483 # making threading more efficient than multiprocessing in
                    484 # that case. However, for joblib 0.12+ we respect any
                    485 # parallel_backend contexts set at a higher level,
                    486 # since correctness does not rely on using threads.
                --> 487 trees = Parallel(
                    488     n_jobs=self.n_jobs,
                    489     verbose=self.verbose,
                    490     prefer="threads",
                    491 )(
                    492     delayed(_parallel_build_trees)(
                    493         t,
                    494         self.bootstrap,
                    495         X,
                    496         y,
                    497         sample_weight,
                    498         i,
                    499         len(trees),
                    500         verbose=self.verbose,
                    501         class_weight=self.class_weight,
                    502         n_samples_bootstrap=n_samples_bootstrap,
                    503         missing_values_in_feature_mask=missing_values_in_feature_mask,
                    504     )
                    505     for i, t in enumerate(trees)
                    506 )
                    508 # Collect newly grown trees
                    509 self.estimators_.extend(trees)
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/utils/parallel.py:77, in Parallel.__call__(self, iterable)
                     72 config = get_config()
                     73 iterable_with_config = (
                     74     (_with_config(delayed_func, config), args, kwargs)
                     75     for delayed_func, args, kwargs in iterable
                     76 )
                ---> 77 return super().__call__(iterable_with_config)
                
                File ~/anaconda3/lib/python3.12/site-packages/joblib/parallel.py:1918, in Parallel.__call__(self, iterable)
                   1916     output = self._get_sequential_output(iterable)
                   1917     next(output)
                -> 1918     return output if self.return_generator else list(output)
                   1920 # Let's create an ID that uniquely identifies the current call. If the
                   1921 # call is interrupted early and that the same instance is immediately
                   1922 # re-used, this id will be used to prevent workers that were
                   1923 # concurrently finalizing a task from the previous call to run the
                   1924 # callback.
                   1925 with self._lock:
                
                File ~/anaconda3/lib/python3.12/site-packages/joblib/parallel.py:1847, in Parallel._get_sequential_output(self, iterable)
                   1845 self.n_dispatched_batches += 1
                   1846 self.n_dispatched_tasks += 1
                -> 1847 res = func(*args, **kwargs)
                   1848 self.n_completed_tasks += 1
                   1849 self.print_progress()
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/utils/parallel.py:139, in _FuncWrapper.__call__(self, *args, **kwargs)
                    137     config = {}
                    138 with config_context(**config):
                --> 139     return self.function(*args, **kwargs)
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/ensemble/_forest.py:189, in _parallel_build_trees(tree, bootstrap, X, y, sample_weight, tree_idx, n_trees, verbose, class_weight, n_samples_bootstrap, missing_values_in_feature_mask)
                    186     elif class_weight == "balanced_subsample":
                    187         curr_sample_weight *= compute_sample_weight("balanced", y, indices=indices)
                --> 189     tree._fit(
                    190         X,
                    191         y,
                    192         sample_weight=curr_sample_weight,
                    193         check_input=False,
                    194         missing_values_in_feature_mask=missing_values_in_feature_mask,
                    195     )
                    196 else:
                    197     tree._fit(
                    198         X,
                    199         y,
                   (...)
                    202         missing_values_in_feature_mask=missing_values_in_feature_mask,
                    203     )
                
                File ~/anaconda3/lib/python3.12/site-packages/sklearn/tree/_classes.py:472, in BaseDecisionTree._fit(self, X, y, sample_weight, check_input, missing_values_in_feature_mask)
                    461 else:
                    462     builder = BestFirstTreeBuilder(
                    463         splitter,
                    464         min_samples_split,
                   (...)
                    469         self.min_impurity_decrease,
                    470     )
                --> 472 builder.build(self.tree_, X, y, sample_weight, missing_values_in_feature_mask)
                    474 if self.n_outputs_ == 1 and is_classifier(self):
                    475     self.n_classes_ = self.n_classes_[0]
                
                KeyboardInterrupt: 
                R² Modelo NADH: 0.8695652173913043
                R² Modelo Biomassa: 0.8913043478260869
                
                [61]:
                Text(0, 0.5, 'Produçao Real de NADH')
                [63]:
                Text(0, 0.5, 'Produçao Real de Biomassa')
                [29]:
                Text(0.5, 1.0, 'Curva ROC AUC')
                • Melhores Fluxos Interativo.ipynb
                • Grafico.ipynb
                • Analises iCH360.ipynb
                • Growth_Couple_iCH360.ipynb
                • Final.ipynb
                • Clusters.ipynb
                • Escher.ipynb
                • IC-PIBIC_pt2.ipynb
                Notebook
                Python (escher)
                Kernel status: Idle
                  /home/cristian/.conda/envs/escher/bin/python
                  
                  Set parameter Username
                  Set parameter LicenseID to value 2644080
                  Academic license - for non-commercial use only - expires 2026-03-29
                  
                  [7]:
                  model.reactions.get_by_id('GLCptspp').bounds = (15,15)
                  model.reactions.get_by_id('PDH').bounds = (1.85,1.85)
                  model.reactions.get_by_id('FUM').bounds = (1.6,1.6)
                  model.reactions.get_by_id('PPC').bounds = (0.36,0.36)
                  [9]:
                  solution = model.optimize()

                  escher_builder = escher.Builder(
                  map_name='iJO1366.Central metabolism',
                  reaction_scale=[{'type': 'min', 'color': '#0000ff', 'size': 10},
                  {'type': 'mean', 'color': '#551a8b', 'size': 20},
                  {'type': 'max', 'color': '#ff0000', 'size': 40}],

                  hide_secondary_metabolites = True,
                  reaction_data = solution.fluxes,

                  )
                  display(escher_builder)
                  Downloading Map from https://escher.github.io/1-0-0/6/maps/Escherichia%20coli/iJO1366.Central%20metabolism.json
                  
                  [ ]:

                  [ ]:

                  ## PDH

                  PDH¶

                  [4]:
                  ijo_h2 = model.copy()
                  Read LP format model from file /tmp/tmptzywuw6q.lp
                  Reading time = 0.01 seconds
                  : 1805 rows, 5166 columns, 20366 nonzeros
                  
                  [5]:
                  ijo_h2.reactions.get_by_id('EX_o2_e').bounds = (0,0)
                  ijo_h2.reactions.get_by_id('EX_mal__L_e').bounds = (-6,-6)

                  ijo_h2.add_metabolites([cobra.Metabolite('fdrd_c'), # Reduced Ferredoxin
                  cobra.Metabolite('fdox_c') # Oxided Ferredoxin
                  ])

                  # Create reactions
                  FNOR = cobra.Reaction('FNOR')
                  HYDA = cobra.Reaction('HYDA')

                  # Add reactions to model
                  ijo_h2.add_reactions([FNOR,
                  HYDA])

                  # Define reaction equations
                  FNOR.reaction = '1 h_c + 1 fdox_c + nadh_c-> 1 fdrd_c + 1 nad_c'
                  HYDA.reaction = '1 fdrd_c -> 1 h_c + 1 h2_c + 1 fdox_c'

                  FNOR.gene_reaction_rule = 'fnor'
                  HYDA.gene_reaction_rule = 'hyda'

                  ijo_h2.reactions.ACALD.knock_out()
                  ijo_h2.reactions.EX_for_e.knock_out()
                  ijo_h2.reactions.EX_lac__D_e.knock_out()
                  ijo_h2.reactions.EX_pyr_e.knock_out()
                  ijo_h2.reactions.PFL.knock_out()
                  ijo_h2.reactions.SUCCt3pp.knock_out()

                  solution = ijo_h2.optimize()

                  escher_builder = escher.Builder(
                  map_name='iJO1366.Central metabolism',
                  reaction_scale=[{'type': 'min', 'color': '#0000ff', 'size': 10},
                  {'type': 'mean', 'color': '#551a8b', 'size': 20},
                  {'type': 'max', 'color': '#ff0000', 'size': 40}],

                  hide_secondary_metabolites = True,
                  reaction_data = solution.fluxes,

                  )
                  display(escher_builder)
                  Downloading Map from https://escher.github.io/1-0-0/6/maps/Escherichia%20coli/iJO1366.Central%20metabolism.json
                  
                  Error displaying widget: model not found
                  ## PFL

                  PFL¶

                  Common Tools
                  No metadata.
                  Advanced Tools
                  No metadata.

                  -

                  Variables

                  Callstack

                    Breakpoints

                    Source

                    9
                    1

                    Kernel Sources

                      9
                      Python (escher) | Idle
                      Uploading…

                      Mode: Command
                      Ln 4, Col 41
                      Spaces: 4
                      Escher.ipynb
                      1
                      Notebook
                      Python 3 (ipykernel)
                      Kernel status: Idle
                      Alt+[
                      Alt+]
                      Tab
                      Notebook
                      Python (cnapy)
                      Kernel status: Idle
                      Alt+[
                      Alt+]
                      Tab
                      Notebook
                      Python (me25)
                      Kernel status: Idle
                      Alt+[
                      Alt+]
                      Tab
                      Alt+[
                      Alt+]
                      Tab
                      Notebook
                      Python (me25)
                      Kernel status: Idle
                      Alt+[
                      Alt+]
                      Tab
                      Notebook
                      Python (me25)
                      Kernel status: Idle
                      Alt+[
                      Alt+]
                      Tab
                      Notebook
                      Python (me25)
                      Kernel status: Idle
                      Alt+[
                      Alt+]
                      Tab
                      Notebook
                      Python (me25)
                      Kernel status: Idle
                      Alt+[
                      Alt+]
                      Tab
                        Alt+[
                        Alt+]
                        Tab